Arquivos
hhvm/hphp/test/quick/closure_in_generator2.php
T
ptarjan 503f75d08b Rename test directories
These names don't make sense now that we run both suites the same
way.
2013-04-17 09:06:51 -07:00

21 linhas
249 B
PHP

<?php
class A {
public function b() {
$cl = function() {
yield $this->c();
};
yield $cl();
}
private function c() {
return 'A';
}
}
$a = new A;
foreach ($a->b() as $c) {
foreach ($c as $d) {
print "$d\n";
}
}