summaryrefslogtreecommitdiff
path: root/Zend/tests/bug76860_2.phpt
diff options
context:
space:
mode:
Diffstat (limited to 'Zend/tests/bug76860_2.phpt')
-rw-r--r--Zend/tests/bug76860_2.phpt34
1 files changed, 34 insertions, 0 deletions
diff --git a/Zend/tests/bug76860_2.phpt b/Zend/tests/bug76860_2.phpt
new file mode 100644
index 0000000000..bc92702fc1
--- /dev/null
+++ b/Zend/tests/bug76860_2.phpt
@@ -0,0 +1,34 @@
+--TEST--
+Bug #76860 (Missed "Accessing static property as non static" warning)
+--FILE--
+<?php
+class A {
+ private static $a = "a";
+ private static $b = "b";
+ private static $c = "c";
+ public function __construct() {
+ var_dump($this->a, $this->b, $this->c);
+ }
+}
+class B extends A {
+ private static $a = "a1";
+ protected static $b = "b1";
+ public static $c = "c1";
+}
+new B;
+?>
+--EXPECTF--
+Notice: Accessing static property B::$a as non static in %sbug76860_2.php on line 7
+
+Notice: Undefined property: B::$a in %sbug76860_2.php on line 7
+
+Notice: Accessing static property B::$b as non static in %sbug76860_2.php on line 7
+
+Notice: Undefined property: B::$b in %sbug76860_2.php on line 7
+
+Notice: Accessing static property B::$c as non static in %sbug76860_2.php on line 7
+
+Notice: Undefined property: B::$c in %sbug76860_2.php on line 7
+NULL
+NULL
+NULL