bug31141.phpt 427 B

12345678910111213141516171819202122232425262728
  1. --TEST--
  2. Bug #31141 (properties declared in the class extending MySQLi are not available)
  3. --EXTENSIONS--
  4. mysqli
  5. --FILE--
  6. <?php
  7. class Test extends mysqli
  8. {
  9. public $test = array();
  10. function foo()
  11. {
  12. $ar_test = array("foo", "bar");
  13. $this->test = &$ar_test;
  14. }
  15. }
  16. $my_test = new Test;
  17. $my_test->foo();
  18. var_dump($my_test->test);
  19. ?>
  20. --EXPECTF--
  21. array(2) {
  22. [0]=>
  23. %s(3) "foo"
  24. [1]=>
  25. %s(3) "bar"
  26. }