diff options
Diffstat (limited to 'tests/lang/foreachLoop.015.phpt')
-rw-r--r-- | tests/lang/foreachLoop.015.phpt | 35 |
1 files changed, 22 insertions, 13 deletions
diff --git a/tests/lang/foreachLoop.015.phpt b/tests/lang/foreachLoop.015.phpt index f7f5389395..13333ccf4d 100644 --- a/tests/lang/foreachLoop.015.phpt +++ b/tests/lang/foreachLoop.015.phpt @@ -490,18 +490,21 @@ array(3) { } --> Do loop: iteration 0: $k=0; $v=v.0 - iteration 1: $k=3; $v=v.2 + iteration 1: $k=2; $v=v.1 + iteration 2: $k=4; $v=v.2 --> State of array after loop: -array(5) { +array(6) { [0]=> - string(5) "new.1" + string(5) "new.2" [1]=> - string(5) "new.0" + string(5) "new.1" [2]=> - string(3) "v.0" + string(5) "new.0" [3]=> - string(3) "v.1" + string(3) "v.0" [4]=> + string(3) "v.1" + [5]=> &string(3) "v.2" } @@ -519,19 +522,25 @@ array(4) { } --> Do loop: iteration 0: $k=0; $v=v.0 - iteration 1: $k=4; $v=v.3 + iteration 1: $k=2; $v=v.1 + iteration 2: $k=4; $v=v.2 + iteration 3: $k=6; $v=v.3 --> State of array after loop: -array(6) { +array(8) { [0]=> - string(5) "new.1" + string(5) "new.3" [1]=> - string(5) "new.0" + string(5) "new.2" [2]=> - string(3) "v.0" + string(5) "new.1" [3]=> - string(3) "v.1" + string(5) "new.0" [4]=> - string(3) "v.2" + string(3) "v.0" [5]=> + string(3) "v.1" + [6]=> + string(3) "v.2" + [7]=> &string(3) "v.3" } |