3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php function &myFunction() { $string = "MyString"; var_dump($string); return $undefined; } for($i = 0; $i < 10; $i++) { $retval = myFunction(); }?>
based on WZJgS
Output for 4.3.0 - 7.2.0
string(8) "MyString" string(8) "MyString" string(8) "MyString" string(8) "MyString" string(8) "MyString" string(8) "MyString" string(8) "MyString" string(8) "MyString" string(8) "MyString" string(8) "MyString"