3v4l.org

run code in 300+ PHP versions simultaneously
<?php var_dump( (new DateTimeImmutable()) ->modify('potato') );
Output for 8.3.0 - 8.3.7
Fatal error: Uncaught DateMalformedStringException: DateTimeImmutable::modify(): Failed to parse time string (potato) at position 0 (p): The timezone could not be found in the database in /in/Xrjlc:6 Stack trace: #0 /in/Xrjlc(6): DateTimeImmutable->modify('potato') #1 {main} thrown in /in/Xrjlc on line 6
Process exited with code 255.
Output for 7.4.0 - 7.4.33, 8.0.1 - 8.0.30, 8.1.0 - 8.1.28, 8.2.0 - 8.2.19
Warning: DateTimeImmutable::modify(): Failed to parse time string (potato) at position 0 (p): The timezone could not be found in the database in /in/Xrjlc on line 6 bool(false)

preferences:
122.99 ms | 406 KiB | 124 Q