php-src/Zend/tests/error_reporting08.phpt

33 lines
428 B
Plaintext
Raw Normal View History

2005-09-23 17:39:00 +08:00
--TEST--
testing @ and error_reporting - 8
--FILE--
<?php
2019-07-14 09:45:31 +08:00
error_reporting(E_ALL & ~E_DEPRECATED);
2018-09-17 01:16:42 +08:00
2005-09-23 17:39:00 +08:00
function foo1($arg) {
}
function foo2($arg) {
}
function foo3() {
2019-07-14 09:45:31 +08:00
error_reporting(E_ALL);
2005-09-23 17:39:00 +08:00
echo $undef3;
throw new Exception("test");
}
try {
@foo1(@foo2(@foo3()));
} catch (Exception $e) {
}
var_dump(error_reporting());
echo "Done\n";
?>
2018-09-17 01:16:42 +08:00
--EXPECTF--
Warning: Undefined variable: undef3 in %s on line %d
2008-07-21 20:23:38 +08:00
int(32767)
2005-09-23 17:39:00 +08:00
Done