xref: /PHP-8.1/Zend/tests/bug76430.phpt (revision 93641539)
1--TEST--
2Bug #76430: __METHOD__ inconsistent outside of method
3--FILE--
4<?php
5
6class Foo {
7    const X = __METHOD__;
8}
9function foo() {
10    class Bar {
11        const X = __METHOD__;
12    }
13}
14
15foo();
16var_dump(Foo::X);
17var_dump(Bar::X);
18
19?>
20--EXPECT--
21string(0) ""
22string(0) ""
23