Mantis - Quercus
Viewing Issue Advanced Details
2940 major always 09-16-08 11:32 09-16-08 15:38
koreth  
ferg  
normal  
closed 3.2.1  
fixed  
none    
none 3.2.1  
0002940: String modifications leak across invocations in compiled mode
<?php
function modify(&$str) {
  $str[3] = 'x';
}
$foo = 'yyyyyy';
print $foo;
modify($foo);


In interpreted mode, this prints "yyyyyy" consistently. In compiled mode, after it's run once, it prints "yyyxyy" -- the modification from the previous run is being retained.

Notes
(0003446)
ferg   
09-16-08 15:38   
php/33mg