Return to bug22592.phpt CVS log | Up to [ELWIX - Embedded LightWeight unIX -] / embedaddon / php / tests / strings |
1.1 ! misho 1: --TEST-- ! 2: Bug #22592 (Cascading assignments to strings with curly braces broken) ! 3: --FILE-- ! 4: <?php ! 5: $wrong = $correct = 'abcdef'; ! 6: ! 7: $t = $x[] = 'x'; ! 8: ! 9: var_dump($correct); ! 10: var_dump($wrong); ! 11: ! 12: $correct[1] = '*'; ! 13: $correct[3] = '*'; ! 14: $correct[5] = '*'; ! 15: ! 16: // This produces the ! 17: $wrong[1] = $wrong[3] = $wrong[5] = '*'; ! 18: ! 19: var_dump($correct); ! 20: var_dump($wrong); ! 21: ! 22: ?> ! 23: --EXPECT-- ! 24: string(6) "abcdef" ! 25: string(6) "abcdef" ! 26: string(6) "a*c*e*" ! 27: string(6) "a*c*e*"