1
0
mirror of https://github.com/php/php-src.git synced 2026-03-24 00:02:20 +01:00

Merge branch 'PHP-8.5'

* PHP-8.5:
  Fix incorrect property_info sizing for locally shadowed trait properties
This commit is contained in:
Ilija Tovilo
2026-03-09 13:50:59 +01:00
2 changed files with 32 additions and 3 deletions

31
Zend/tests/gh20672.phpt Normal file
View File

@@ -0,0 +1,31 @@
--TEST--
GH-20672: Incorrect property_info sizing for locally shadowed trait properties
--CREDITS--
Jonne Ransijn (yyny)
--FILE--
<?php
trait T {
public static $a;
public static $b;
public static $c;
}
class Base {
public $x;
public $y;
}
class Child extends Base {
public static $a;
public static $b;
public static $c;
public static $d;
use T;
}
?>
===DONE===
--EXPECT--
===DONE===

View File

@@ -2925,9 +2925,7 @@ static void zend_do_traits_property_binding(zend_class_entry *ce, zend_class_ent
ZSTR_VAL(prop_name),
ZSTR_VAL(ce->name));
}
if (!(flags & ZEND_ACC_STATIC)) {
continue;
}
continue;
}
}