3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php $milliseconds = 1000; var_dump($milliseconds); $conversionResult = $milliseconds * pow( 10, 6 ); var_dump($conversionResult); var_dump(PHP_INT_MAX); time_nanosleep(0, $conversionResult);
based on gEFiP
Output for 5.6.0 - 5.6.30, 7.0.0 - 7.3.0alpha1
int(1000) int(1000000000) int(9223372036854775807) Warning: time_nanosleep(): nanoseconds was not in the range 0 to 999 999 999 or seconds was negative in /in/aMI67 on line 8
Output for hhvm-3.12.14 - 3.17.3
int(1000) int(1000000000) int(9223372036854775807) Warning: Invalid argument: nanoseconds: has to be 0 to 999999999 in /in/aMI67 on line 8