3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php $i=new \DateInterval("5 minute"); var_dump($i);
Output for 7.0.0 - 7.2.0
Fatal error: Uncaught Exception: DateInterval::__construct(): Unknown or bad format (5 minute) in /in/2jn2d:3 Stack trace: #0 /in/2jn2d(3): DateInterval->__construct('5 minute') #1 {main} thrown in /in/2jn2d on line 3
Process exited with code 255.
Output for hhvm-3.10.1 - 3.17.3
Fatal error: Uncaught exception 'Exception' with message 'DateInterval::__construct: Invalid interval (5 minute)' in /in/2jn2d:3 Stack trace: #0 /in/2jn2d(3): DateInterval->__construct() #1 {main}
Process exited with code 255.
Output for 5.5.0 - 5.6.30
Fatal error: Uncaught exception 'Exception' with message 'DateInterval::__construct(): Unknown or bad format (5 minute)' in /in/2jn2d:3 Stack trace: #0 /in/2jn2d(3): DateInterval->__construct('5 minute') #1 {main} thrown in /in/2jn2d on line 3
Process exited with code 255.