php-src/Zend/tests/bug76430.phpt
Nikita Popov 9364153942 Fixed bug #76430
It's somewhat ambiguous what exactly the correct behavior is
supposed to be, I'm just picking something more or less reasonable
here.
2019-02-12 17:36:07 +01:00

23 lines
275 B
PHP

--TEST--
Bug #76430: __METHOD__ inconsistent outside of method
--FILE--
<?php
class Foo {
const X = __METHOD__;
}
function foo() {
class Bar {
const X = __METHOD__;
}
}
foo();
var_dump(Foo::X);
var_dump(Bar::X);
?>
--EXPECT--
string(0) ""
string(0) ""