1--TEST--
2Evaluation order during assignments.
3--FILE--
4<?php
5
6function i1() {
7        echo "i1\n";
8        return 0;
9}
10
11function i2() {
12        echo "i2\n";
13        return 0;
14}
15
16function i3() {
17        echo "i3\n";
18        return 0;
19}
20
21function i4() {
22        echo "i4\n";
23        return 0;
24}
25
26function i5() {
27        echo "i5\n";
28        return 0;
29}
30
31function i6() {
32        echo "i6\n";
33        return 0;
34}
35
36$a = array(array(0));
37$b = array(array(1));
38$c = array(array(2));
39
40$a[i1()][i2()] = $b[i3()][i4()] = $c[i5()][i6()];
41
42var_dump($a);
43var_dump($b);
44var_dump($c);
45
46?>
47--EXPECT--
48i1
49i2
50i3
51i4
52i5
53i6
54array(1) {
55  [0]=>
56  array(1) {
57    [0]=>
58    int(2)
59  }
60}
61array(1) {
62  [0]=>
63  array(1) {
64    [0]=>
65    int(2)
66  }
67}
68array(1) {
69  [0]=>
70  array(1) {
71    [0]=>
72    int(2)
73  }
74}
75