php-src/Zend/tests/bug69676.phpt
Nikita Popov 3dba00bc31 Fix scope_is_known() for class constants
Here the active_op_array is still the surrounding file, but we
do know the scope.
2015-05-21 21:07:05 +02:00

20 lines
336 B
PHP

--TEST--
Bug #69676: Resolution of self::FOO in class constants not correct
--FILE--
<?php
class A {
const myConst = "const in A";
const myDynConst = self::myConst;
}
class B extends A {
const myConst = "const in B";
}
var_dump(B::myDynConst);
var_dump(A::myDynConst);
?>
--EXPECT--
string(10) "const in A"
string(10) "const in A"