2008-01-30 22:25:57 +08:00
|
|
|
--TEST--
|
|
|
|
Redeclare inherited private static property as protected static.
|
|
|
|
--FILE--
|
|
|
|
<?php
|
|
|
|
class A
|
|
|
|
{
|
|
|
|
private static $p = "A::p (static)";
|
|
|
|
static function showA()
|
|
|
|
{
|
|
|
|
echo self::$p . "\n";
|
|
|
|
}
|
|
|
|
}
|
2018-09-17 01:16:42 +08:00
|
|
|
|
2008-01-30 22:25:57 +08:00
|
|
|
class B extends A
|
|
|
|
{
|
|
|
|
protected static $p = "B::p (static)";
|
|
|
|
static function showB()
|
|
|
|
{
|
|
|
|
echo self::$p . "\n";
|
|
|
|
}
|
|
|
|
}
|
2018-09-17 01:16:42 +08:00
|
|
|
|
|
|
|
|
2008-01-30 22:25:57 +08:00
|
|
|
A::showA();
|
2018-09-17 01:16:42 +08:00
|
|
|
|
2008-01-30 22:25:57 +08:00
|
|
|
B::showA();
|
|
|
|
B::showB();
|
|
|
|
?>
|
2018-02-19 16:59:41 +08:00
|
|
|
--EXPECT--
|
2008-01-30 22:25:57 +08:00
|
|
|
A::p (static)
|
|
|
|
A::p (static)
|
|
|
|
B::p (static)
|