2006-10-09 16:02:34 +00:00
|
|
|
--TEST--
|
|
|
|
Catchable fatal error [2]
|
|
|
|
--FILE--
|
|
|
|
<?php
|
|
|
|
class Foo {
|
|
|
|
}
|
|
|
|
|
|
|
|
function blah (Foo $a)
|
|
|
|
{
|
|
|
|
}
|
|
|
|
|
|
|
|
function error()
|
|
|
|
{
|
|
|
|
$a = func_get_args();
|
|
|
|
var_dump($a);
|
|
|
|
}
|
|
|
|
|
|
|
|
set_error_handler('error');
|
|
|
|
|
2015-03-09 12:57:15 +00:00
|
|
|
try {
|
|
|
|
blah (new StdClass);
|
2015-05-16 21:49:14 +00:00
|
|
|
} catch (Error $ex) {
|
2015-03-09 12:57:15 +00:00
|
|
|
echo $ex->getMessage(), "\n";
|
|
|
|
}
|
2006-10-09 16:02:34 +00:00
|
|
|
echo "ALIVE!\n";
|
|
|
|
?>
|
|
|
|
--EXPECTF--
|
2015-03-20 14:26:12 +00:00
|
|
|
Argument 1 passed to blah() must be an instance of Foo, instance of stdClass given, called in %scatchable_error_002.php on line %d
|
2006-10-09 16:02:34 +00:00
|
|
|
ALIVE!
|