3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php class ContinueException extends Exception {} var_dump((function () { for ($i = 0; $i < 5; $i++) { try { try { return $i; } finally { if ($i != 3) throw new ContinueException; } } catch (ContinueException $e) { continue; } } })());
based on HeW4t
Output for 7.0.0 - 7.2.0
int(3)
Output for 5.5.24 - 5.6.28
Parse error: syntax error, unexpected '(' in /in/W967o on line 17
Process exited with code 255.
Output for 5.4.10 - 5.4.45
Parse error: syntax error, unexpected 'finally' (T_STRING), expecting catch (T_CATCH) in /in/W967o on line 10
Process exited with code 255.
Output for 5.3.20 - 5.3.29
Parse error: syntax error, unexpected T_STRING, expecting T_CATCH in /in/W967o on line 10
Process exited with code 255.