Fix memoization of functions called with keyset arguments
[hiphop-php.git] / hphp / test / quick / cyclic_props.php
blobeb7a41cba6e821e51ee42b2a33336ac14c88af76
1 <?php
2 class x {
3 public $x0;
4 public $y1;
7 function cyclic_prop_declared_props() {
8 $a = new x;
9 $a->x0 = new x;
10 $a->x0->y1 =& $a->x0;
11 var_dump($a);
12 var_dump($a->x0->y1 = "ok");
15 function cyclic_prop_nondeclared_props() {
16 $a = new stdClass;
17 $a->x0 = new stdClass;
18 $a->x0->y0 = 'a';
19 $a->x0->y1 =& $a->x0;
20 $a->x0->y2 =& $a->x0;
21 $a->x0->y0 = 'b';
22 var_dump($a);
23 var_dump($a->x0->y1 = "ok");
24 var_dump($a->x0);
27 cyclic_prop_declared_props();
28 cyclic_prop_nondeclared_props();