]> granicus.if.org Git - php/commitdiff
Merge branch 'PHP-7.4'
authorNikita Popov <nikita.ppv@gmail.com>
Mon, 31 Aug 2020 13:10:34 +0000 (15:10 +0200)
committerNikita Popov <nikita.ppv@gmail.com>
Mon, 31 Aug 2020 13:10:53 +0000 (15:10 +0200)
* PHP-7.4:
  Fix leak on consteval exception in ReflectionClass::__toString()

1  2 
ext/reflection/php_reflection.c
ext/reflection/tests/ReflectionClass_toString_004.phpt

Simple merge
index 0000000000000000000000000000000000000000,04b42d0792198a14809fe039f060ddb7fdd5cc2a..0eecb3c8a3460fb1554b51749986c23a4bfa3486
mode 000000,100644..100644
--- /dev/null
@@@ -1,0 -1,17 +1,17 @@@
 -Undefined class constant 'self::UNKNOWN'
+ --TEST--
+ Constant evaluation exception during ReflectionClass::__toString()
+ --FILE--
+ <?php
+ class A {
+     const C = self::UNKNOWN;
+ }
+ try {
+     echo new ReflectionClass(A::class);
+ } catch (Error $e) {
+     echo $e->getMessage(), "\n";
+ }
+ ?>
+ --EXPECT--
++Undefined constant self::UNKNOWN