Annotation of embedaddon/php/ext/standard/tests/strings/bug22224.phpt, revision 1.1.1.1
1.1 misho 1: --TEST--
2: Bug #22224 (implode changes object references in array)
3: --INI--
4: error_reporting=0
5: --FILE--
6: <?php
7: class foo
8: {
9: function __toString()
10: {
11: return "Object";
12: }
13: }
14:
15:
16: $a = new foo();
17:
18: $arr = array(0=>&$a, 1=>&$a);
19: var_dump(implode(",",$arr));
20: var_dump($arr)
21: ?>
22: --EXPECTF--
23: string(13) "Object,Object"
24: array(2) {
25: [0]=>
26: &object(foo)#%d (0) {
27: }
28: [1]=>
29: &object(foo)#%d (0) {
30: }
31: }
FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>