363d1bb20f
This change is mostly for FB internal organizational reasons. Building is not effected beyond the fact that the target now lands in hphp/hhvm/hhvm rather than src/hhvm/hhvm.
31 linhas
431 B
PHP
31 linhas
431 B
PHP
<?php
|
|
|
|
class Ex1 extends Exception {
|
|
function getString() {
|
|
return "Ex1\n";
|
|
}
|
|
}
|
|
|
|
class Ex2 extends Exception {
|
|
function getString() {
|
|
return "Ex2\n";
|
|
}
|
|
}
|
|
|
|
function foo() {
|
|
throw new Ex2();
|
|
}
|
|
|
|
try {
|
|
foo();
|
|
echo "should not be here\n";
|
|
} catch (Ex1 $e) {
|
|
$a = $e->getString();
|
|
echo "caught exception $a";
|
|
} catch (Ex2 $e) {
|
|
$a = $e->getString();
|
|
echo "caught exception $a";
|
|
}
|
|
|
|
echo "after exception\n";
|