summaryrefslogtreecommitdiff
path: root/Zend/tests/bug34518.phpt
blob: b94fdf49810a275967474166fff56756c10170d9 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
--TEST--
Bug #34518 (Unset doesn't separate container in CV)
--FILE--
<?php
$arr = array(1,2,3);
$arr["foo"] = array(4,5,6);
$copy = $arr;

unset($copy["foo"][0]);
print_r($arr);
print_r($copy);
?>
--EXPECT--
Array
(
    [0] => 1
    [1] => 2
    [2] => 3
    [foo] => Array
        (
            [0] => 4
            [1] => 5
            [2] => 6
        )

)
Array
(
    [0] => 1
    [1] => 2
    [2] => 3
    [foo] => Array
        (
            [1] => 5
            [2] => 6
        )

)