php-src/Zend/tests/bug69676_2.phpt

23 lines
350 B
Plaintext
Raw Normal View History

2017-03-16 02:06:34 +08:00
--TEST--
Bug #69676: Resolution of self::FOO in class constants not correct (variation)
--FILE--
<?php
class Foo {
const A = 'Foo::A';
const B = self::A . ' and ' . self::C;
const C = 'Foo::C';
2018-09-17 01:16:42 +08:00
2017-03-16 02:06:34 +08:00
}
class Bar extends Foo {
const A = 'Bar::A';
const C = 'Bar::C';
}
var_dump(Bar::B);
?>
--EXPECT--
string(17) "Foo::A and Foo::C"