3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php $dt = new \DateTimeImmutable('-1 week'); $dt2 = new \DateTimeImmutable(); var_dump($dt <=> $dt2); var_dump($dt2 <=> $dt);
Output for hhvm-3.18.5 - 3.22.0, 7.0.30 - 7.3.0alpha1
int(-1) int(1)
Output for 5.6.30
Parse error: syntax error, unexpected '>' in /in/A230M on line 5
Process exited with code 255.