bug46106.phpt 323 B

12345678910111213141516171819202122
  1. --TEST--
  2. Bug #46106 (Memory leaks when using global statement)
  3. --FILE--
  4. <?php
  5. $foo = array(1);
  6. function foobar($errno, $errstr, $errfile, $errline) { }
  7. set_error_handler('foobar');
  8. function test($x) {
  9. global $foo;
  10. $x->invokeArgs(array(0));
  11. }
  12. $x = new ReflectionFunction('str_pad');
  13. test($x);
  14. ?>
  15. DONE
  16. --EXPECT--
  17. DONE