We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 3eb97a4 commit 5ac55afCopy full SHA for 5ac55af
NEWS
@@ -10,6 +10,8 @@ PHP NEWS
10
- Reflection:
11
. Fixed bug #80821 (ReflectionProperty::getDefaultValue() returns current
12
value for statics). (Nikita)
13
+ . Fixed bug #80564 (ReflectionProperty::__toString() renders current value,
14
+ not default value). (Nikita)
15
16
22 Jul 2021, PHP 8.1.0beta1
17
ext/reflection/tests/bug80564.phpt
@@ -0,0 +1,17 @@
1
+--TEST--
2
+Bug #80564: ReflectionProperty::__toString() renders current value, not default value
3
+--FILE--
4
+<?php
5
+
6
+class A {
7
+ public static $x = 'default';
8
+}
9
+A::$x = new stdClass;
+$rp = new ReflectionProperty('A', 'x');
+echo $rp;
+?>
+--EXPECT--
+Property [ public static $x = 'default' ]
0 commit comments