3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php class A extends DOMDocument { const TEST = false; public function test() { var_dump(static::TEST); } } class B extends A { const TEST = true; public function test() { A::test(); parent::test(); } } $b = new B; $b->test();
based on dcpZU
Output for 5.3.20 - 5.6.28, 7.0.1 - 7.2.0
bool(true) bool(true)
Output for 7.0.0
bool(false) bool(true)