mirror of
https://github.com/php/php-src.git
synced 2024-12-18 06:21:41 +08:00
7aacc705d0
Closes GH-5958
28 lines
369 B
PHP
28 lines
369 B
PHP
--TEST--
|
|
Bug #70997 (When using parentClass:: instead of parent::, static context changed)
|
|
--FILE--
|
|
<?php
|
|
class A {
|
|
const TEST = false;
|
|
|
|
public function test()
|
|
{
|
|
var_dump(static::TEST);
|
|
}
|
|
}
|
|
|
|
class B extends A {
|
|
const TEST = true;
|
|
|
|
public function test()
|
|
{
|
|
A::test();
|
|
}
|
|
}
|
|
|
|
$b = new B;
|
|
$b->test();
|
|
?>
|
|
--EXPECT--
|
|
bool(true)
|