File tree 2 files changed +34
-0
lines changed
2 files changed +34
-0
lines changed Original file line number Diff line number Diff line change @@ -1746,6 +1746,12 @@ static uint32_t get_ssa_alias_types(zend_ssa_alias_kind alias) {
1746
1746
} \
1747
1747
if (__var >= 0) { \
1748
1748
zend_ssa_var *__ssa_var = &ssa_vars[__var]; \
1749
+ if (__ssa_var->var < op_array->num_args) { \
1750
+ if (__type & MAY_BE_RC1) { \
1751
+ /* TODO: may be captured by exception backtreace */ \
1752
+ __type |= MAY_BE_RCN ; \
1753
+ } \
1754
+ } \
1749
1755
if (__ssa_var -> var < op_array -> last_var ) { \
1750
1756
if (__type & (MAY_BE_REF |MAY_BE_RCN )) { \
1751
1757
__type |= MAY_BE_RC1 | MAY_BE_RCN ; \
Original file line number Diff line number Diff line change
1
+ --TEST--
2
+ GH-12509: JIT assertion when running php-parser tests
3
+ --INI--
4
+ opcache.enable=1
5
+ opcache.enable_cli=1
6
+ --FILE--
7
+ <?php
8
+ function capture () {
9
+ $ GLOBALS ["x " ] = new Exception ();
10
+ }
11
+ function test ($ a ) {
12
+ $ a [1 ] = 1 ;
13
+ $ a [2 ] = 2 ;
14
+ capture ();
15
+ $ a [3 ] = 3 ;
16
+ return $ a ;
17
+ }
18
+ var_dump (test ([]));
19
+ ?>
20
+ --EXPECT--
21
+ array(3) {
22
+ [1]=>
23
+ int(1)
24
+ [2]=>
25
+ int(2)
26
+ [3]=>
27
+ int(3)
28
+ }
You can’t perform that action at this time.
0 commit comments