mirror of
https://github.com/php/php-src.git
synced 2024-09-23 19:07:26 +00:00
16 lines
235 B
Plaintext
16 lines
235 B
Plaintext
|
--TEST--
|
||
|
Bug #70397 (Segmentation fault when using Closure::call and yield)
|
||
|
--FILE--
|
||
|
<?php
|
||
|
|
||
|
$f = function () {
|
||
|
$this->value = true;
|
||
|
yield $this->value;
|
||
|
};
|
||
|
|
||
|
var_dump($f->call(new class {})->current());
|
||
|
|
||
|
?>
|
||
|
--EXPECT--
|
||
|
bool(true)
|