3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php function gen1() { yield 1; yield 2; yield 3; } function gen2(bool $opt) { if ($opt) return gen1(); yield 4; yield 5; yield 6; } gen2(true); gen2(false);