add bitset operations and tests
[hiphop-php.git] / hphp / test / slow / object_property_expression / 793.php
blob652ec351c1555bac3a7699b9b066251c7b9d23be
1 <?php
3 class C1 {
5 class C2 {
6 public function __get( $what ) {
7 echo "get C2
8 ";
9 return $this->_p[ $what ];
11 public function __set( $what, $value ) {
12 echo "set C2
14 $this->_p[ $what ] = $value;
16 private $_p = array();
18 class C3 {
19 public function __get( $what ) {
20 echo "get C3
22 return $this->_p[ $what ];
24 public function __set( $what, $value ) {
25 echo "set C3
27 $this->_p[ $what ] = $value;
29 private $_p = array();
31 function assign_ref(&$v) {
32 $v = 22;
34 $c3 = new C3();
35 $c3->p3 = new C2();
36 $c3->p3->p2 = new C1();
37 $c3->p3->p2->a = 1;
38 $c3->p3->p2->a .= 1;
39 print $c3->p3->p2->a;
40 assign_ref($c3->p3->p2->a);
41 print $c3->p3->p2->a;