Arquivos
hhvm/hphp/test/quick/debugger/exception1.php
T
Herman Venter bca91c8ef3 Really turn off tutorial output this time and re-enable tests that failed because of tutorial mode.
It turns out that Tutorial=0 means "auto" and -1 means "off". With auto tutorials, the hphpd.hdf file got updated and test behavior got flaky. Even worse, the non ASCII characters in the tutorial output broke the test runner in a way that made it look like tests passed when you put up a differential, only to fail in contbuild.
2013-06-28 11:36:10 -07:00

59 linhas
887 B
PHP

<?php
// Warning: line numbers are sensitive, do not change
namespace {
class MyException extends Exception { }
class NotAnException { }
function throw_exception() {
throw new Exception();
}
function throw_myexception() {
throw new MyException();
}
function error_undefined_class() {
$x = new NoSuchClass();
}
}
namespace Outer {
class MyException extends \Exception { }
function throw_exception() {
throw new \Exception();
}
function throw_myexception() {
throw new MyException();
}
function error_undefined_class() {
$x = new NoSuchClass();
}
}
namespace Outer\Inner {
class MyException extends \Exception { }
function throw_exception() {
throw new \Exception();
}
function throw_myexception() {
throw new MyException();
}
function error_undefined_class() {
$x = new NoSuchClass();
}
}