call_with_refs.phpt 339 B

123456789101112131415161718
  1. --TEST--
  2. Check call to non-ref function with call-time refs
  3. --FILE--
  4. <?php
  5. class Test {
  6. public function __toString() {
  7. global $my_var;
  8. $my_var=0x12345;
  9. return "";
  10. }
  11. }
  12. $my_var = str_repeat("A",64);
  13. $data = call_user_func_array("substr_replace",array(&$my_var, new Test(), 1));
  14. echo "OK!";
  15. ?>
  16. --EXPECT--
  17. OK!