mirror of
https://github.com/php/php-src.git
synced 2024-09-29 13:56:09 +00:00
17 lines
287 B
Plaintext
17 lines
287 B
Plaintext
|
--TEST--
|
||
|
Bug #71737: Memory leak in closure with parameter named $this
|
||
|
--FILE--
|
||
|
<?php
|
||
|
|
||
|
class Test {
|
||
|
public function method() {
|
||
|
return function($this) {};
|
||
|
}
|
||
|
}
|
||
|
|
||
|
(new Test)->method()(new stdClass);
|
||
|
|
||
|
?>
|
||
|
--EXPECTF--
|
||
|
Fatal error: Cannot use $this as parameter in %s on line %d
|