3v4l.org

run code in 300+ PHP versions simultaneously
<?php function Something() { return "Another"; } class Something {} class Another {}; echo Something() . PHP_EOL; var_dump(new Something()); var_dump(new (Something()));
Output for 8.0.30, 8.1.28 - 8.1.34, 8.2.16 - 8.2.30, 8.3.3 - 8.3.30, 8.4.1 - 8.4.18, 8.5.0 - 8.5.3
Another object(Something)#1 (0) { } object(Another)#1 (0) { }

preferences:
76.81 ms | 795 KiB | 4 Q