mirror of
https://github.com/php/php-src.git
synced 2024-11-23 18:04:36 +08:00
7ce8c5ad89
Closes GH-5465
21 lines
556 B
PHP
21 lines
556 B
PHP
--TEST--
|
|
Error message in error handler during compilation
|
|
--FILE--
|
|
<?php
|
|
|
|
set_error_handler(function($_, $msg, $file) {
|
|
var_dump($msg, $file);
|
|
echo $undefined;
|
|
});
|
|
|
|
/* This is just a particular example of a non-fatal compile-time error
|
|
* If this breaks in future, just find another example and use it instead */
|
|
eval('class A { private function __invoke() { } }');
|
|
|
|
?>
|
|
--EXPECTF--
|
|
string(%d) "The magic method A::__invoke() must have public visibility"
|
|
string(%d) "%s(%d) : eval()'d code"
|
|
|
|
Warning: Undefined variable $undefined in %s on line %d
|