File tree Expand file tree Collapse file tree 2 files changed +20
-3
lines changed Expand file tree Collapse file tree 2 files changed +20
-3
lines changed Original file line number Diff line number Diff line change 1+ --TEST--
2+ IntlTimeZone::getCanonicalID: refs test
3+ --EXTENSIONS--
4+ intl
5+ --FILE--
6+ <?php
7+ class Test {
8+ public string $ prop = "a " ;
9+ }
10+ $ test = new Test ;
11+ $ ref =& $ test ->prop ;
12+ print_R (intltz_get_canonical_id ('Portugal ' , $ ref ));
13+ var_dump ($ test );
14+ ?>
15+ --EXPECT--
16+ Europe/Lisbonobject(Test)#1 (1) {
17+ ["prop"]=>
18+ &string(1) "1"
19+ }
Original file line number Diff line number Diff line change @@ -291,9 +291,7 @@ U_CFUNC PHP_FUNCTION(intltz_get_canonical_id)
291291 RETVAL_NEW_STR (u8str);
292292
293293 if (is_systemid) { /* by-ref argument passed */
294- ZVAL_DEREF (is_systemid);
295- zval_ptr_dtor (is_systemid);
296- ZVAL_BOOL (is_systemid, isSystemID);
294+ ZEND_TRY_ASSIGN_REF_BOOL (is_systemid, isSystemID);
297295 }
298296}
299297
You can’t perform that action at this time.
0 commit comments