3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php var_dump((new DateTimeImmutable)->modify('24 hours'));
Output for 7.2.0
object(DateTimeImmutable)#2 (3) { ["date"]=> string(26) "2015-10-01 16:33:54.003925" ["timezone_type"]=> int(3) ["timezone"]=> string(16) "Europe/Amsterdam" }
Output for 7.1.10
object(DateTimeImmutable)#2 (3) { ["date"]=> string(26) "2015-10-01 16:33:54.004081" ["timezone_type"]=> int(3) ["timezone"]=> string(16) "Europe/Amsterdam" }
Output for 7.1.7
object(DateTimeImmutable)#2 (3) { ["date"]=> string(26) "2015-10-01 16:33:54.004380" ["timezone_type"]=> int(3) ["timezone"]=> string(16) "Europe/Amsterdam" }
Output for 7.1.6
object(DateTimeImmutable)#2 (3) { ["date"]=> string(26) "2015-10-01 16:33:54.009588" ["timezone_type"]=> int(3) ["timezone"]=> string(16) "Europe/Amsterdam" }
Output for 7.1.5
object(DateTimeImmutable)#2 (3) { ["date"]=> string(26) "2015-10-01 16:33:54.011654" ["timezone_type"]=> int(3) ["timezone"]=> string(16) "Europe/Amsterdam" }
Output for 7.1.0
object(DateTimeImmutable)#2 (3) { ["date"]=> string(26) "2015-10-01 16:33:54.004062" ["timezone_type"]=> int(3) ["timezone"]=> string(16) "Europe/Amsterdam" }
Output for 5.6.28, 7.0.20
object(DateTimeImmutable)#2 (3) { ["date"]=> string(26) "2015-10-01 16:33:54.000000" ["timezone_type"]=> int(3) ["timezone"]=> string(16) "Europe/Amsterdam" }
Output for 7.0.6
object(DateTimeImmutable)#2 (3) { ["date"]=> string(26) "2016-05-04 05:02:10.000000" ["timezone_type"]=> int(3) ["timezone"]=> string(16) "Europe/Amsterdam" }
Output for 7.0.5
object(DateTimeImmutable)#2 (3) { ["date"]=> string(26) "2016-04-03 18:10:39.000000" ["timezone_type"]=> int(3) ["timezone"]=> string(16) "Europe/Amsterdam" }
Output for 7.0.4
object(DateTimeImmutable)#2 (3) { ["date"]=> string(26) "2016-03-11 04:00:35.000000" ["timezone_type"]=> int(3) ["timezone"]=> string(16) "Europe/Amsterdam" }
Output for 7.0.3
object(DateTimeImmutable)#2 (3) { ["date"]=> string(26) "2016-03-19 04:19:54.000000" ["timezone_type"]=> int(3) ["timezone"]=> string(16) "Europe/Amsterdam" }
Output for 7.0.2
object(DateTimeImmutable)#2 (3) { ["date"]=> string(26) "2016-03-22 14:47:48.000000" ["timezone_type"]=> int(3) ["timezone"]=> string(16) "Europe/Amsterdam" }
Output for 7.0.1
object(DateTimeImmutable)#2 (3) { ["date"]=> string(26) "2016-03-24 15:26:03.000000" ["timezone_type"]=> int(3) ["timezone"]=> string(16) "Europe/Amsterdam" }
Output for 7.0.0
object(DateTimeImmutable)#2 (3) { ["date"]=> string(26) "2016-03-27 17:16:50.000000" ["timezone_type"]=> int(3) ["timezone"]=> string(16) "Europe/Amsterdam" }
Output for 5.6.21
object(DateTimeImmutable)#2 (3) { ["date"]=> string(26) "2016-05-03 00:06:01.000000" ["timezone_type"]=> int(3) ["timezone"]=> string(16) "Europe/Amsterdam" }
Output for 5.6.20
object(DateTimeImmutable)#2 (3) { ["date"]=> string(26) "2016-04-10 13:25:21.000000" ["timezone_type"]=> int(3) ["timezone"]=> string(16) "Europe/Amsterdam" }
Output for 5.6.19
object(DateTimeImmutable)#2 (3) { ["date"]=> string(26) "2016-03-08 03:25:02.000000" ["timezone_type"]=> int(3) ["timezone"]=> string(16) "Europe/Amsterdam" }
Output for 5.6.18
object(DateTimeImmutable)#2 (3) { ["date"]=> string(26) "2016-03-15 16:57:33.000000" ["timezone_type"]=> int(3) ["timezone"]=> string(16) "Europe/Amsterdam" }
Output for 5.6.17
object(DateTimeImmutable)#2 (3) { ["date"]=> string(26) "2016-03-20 08:44:48.000000" ["timezone_type"]=> int(3) ["timezone"]=> string(16) "Europe/Amsterdam" }
Output for 5.6.16
object(DateTimeImmutable)#2 (3) { ["date"]=> string(26) "2016-03-28 19:02:46.000000" ["timezone_type"]=> int(3) ["timezone"]=> string(16) "Europe/Amsterdam" }
Output for 5.6.15
object(DateTimeImmutable)#2 (3) { ["date"]=> string(26) "2016-03-29 19:54:47.000000" ["timezone_type"]=> int(3) ["timezone"]=> string(16) "Europe/Amsterdam" }
Output for 5.6.14
object(DateTimeImmutable)#2 (3) { ["date"]=> string(26) "2016-04-02 22:28:04.000000" ["timezone_type"]=> int(3) ["timezone"]=> string(16) "Europe/Amsterdam" }
Output for 5.6.13
object(DateTimeImmutable)#2 (3) { ["date"]=> string(26) "2016-04-16 02:27:57.000000" ["timezone_type"]=> int(3) ["timezone"]=> string(16) "Europe/Amsterdam" }
Output for 5.6.12
object(DateTimeImmutable)#2 (3) { ["date"]=> string(26) "2016-04-20 15:45:02.000000" ["timezone_type"]=> int(3) ["timezone"]=> string(16) "Europe/Amsterdam" }
Output for 5.6.11
object(DateTimeImmutable)#2 (3) { ["date"]=> string(26) "2016-04-23 22:52:18.000000" ["timezone_type"]=> int(3) ["timezone"]=> string(16) "Europe/Amsterdam" }
Output for 5.6.10
object(DateTimeImmutable)#2 (3) { ["date"]=> string(26) "2016-04-26 00:30:45.000000" ["timezone_type"]=> int(3) ["timezone"]=> string(16) "Europe/Amsterdam" }
Output for 5.6.9
object(DateTimeImmutable)#2 (3) { ["date"]=> string(26) "2016-04-28 05:43:14.000000" ["timezone_type"]=> int(3) ["timezone"]=> string(16) "Europe/Amsterdam" }
Output for 5.6.8
object(DateTimeImmutable)#2 (3) { ["date"]=> string(26) "2016-04-30 13:31:14.000000" ["timezone_type"]=> int(3) ["timezone"]=> string(16) "Europe/Amsterdam" }
Output for 5.6.7
object(DateTimeImmutable)#2 (3) { ["date"]=> string(26) "2016-05-26 02:04:14.000000" ["timezone_type"]=> int(3) ["timezone"]=> string(16) "Europe/Amsterdam" }
Output for 5.5.35
object(DateTimeImmutable)#2 (3) { ["date"]=> string(26) "2016-05-23 03:50:21.000000" ["timezone_type"]=> int(3) ["timezone"]=> string(16) "Europe/Amsterdam" }
Output for 5.5.34
object(DateTimeImmutable)#2 (3) { ["date"]=> string(26) "2016-04-11 19:22:58.000000" ["timezone_type"]=> int(3) ["timezone"]=> string(16) "Europe/Amsterdam" }
Output for 5.5.33
object(DateTimeImmutable)#2 (3) { ["date"]=> string(26) "2016-03-09 14:54:51.000000" ["timezone_type"]=> int(3) ["timezone"]=> string(16) "Europe/Amsterdam" }
Output for 5.5.32
object(DateTimeImmutable)#2 (3) { ["date"]=> string(26) "2016-03-17 20:45:01.000000" ["timezone_type"]=> int(3) ["timezone"]=> string(16) "Europe/Amsterdam" }
Output for 5.5.31
object(DateTimeImmutable)#2 (3) { ["date"]=> string(26) "2016-03-21 11:36:30.000000" ["timezone_type"]=> int(3) ["timezone"]=> string(16) "Europe/Amsterdam" }
Output for 5.5.30
object(DateTimeImmutable)#2 (3) { ["date"]=> string(26) "2016-04-01 21:55:41.000000" ["timezone_type"]=> int(3) ["timezone"]=> string(16) "Europe/Amsterdam" }
Output for 5.5.29
object(DateTimeImmutable)#2 (3) { ["date"]=> string(26) "2016-04-17 16:32:30.000000" ["timezone_type"]=> int(3) ["timezone"]=> string(16) "Europe/Amsterdam" }
Output for 5.5.28
object(DateTimeImmutable)#2 (3) { ["date"]=> string(26) "2016-04-21 18:55:29.000000" ["timezone_type"]=> int(3) ["timezone"]=> string(16) "Europe/Amsterdam" }
Output for 5.5.27
object(DateTimeImmutable)#2 (3) { ["date"]=> string(26) "2016-04-22 21:18:24.000000" ["timezone_type"]=> int(3) ["timezone"]=> string(16) "Europe/Amsterdam" }
Output for 5.5.26
object(DateTimeImmutable)#2 (3) { ["date"]=> string(26) "2016-04-27 03:05:12.000000" ["timezone_type"]=> int(3) ["timezone"]=> string(16) "Europe/Amsterdam" }
Output for 5.5.25
object(DateTimeImmutable)#2 (3) { ["date"]=> string(26) "2016-04-29 09:02:41.000000" ["timezone_type"]=> int(3) ["timezone"]=> string(16) "Europe/Amsterdam" }
Output for 5.5.24
object(DateTimeImmutable)#2 (3) { ["date"]=> string(26) "2016-05-24 15:54:47.000000" ["timezone_type"]=> int(3) ["timezone"]=> string(16) "Europe/Amsterdam" }
Output for 5.4.2 - 5.4.45
Fatal error: Class 'DateTimeImmutable' not found in /in/BARW9 on line 3
Process exited with code 255.
Output for 5.3.18 - 5.3.29
Parse error: syntax error, unexpected T_OBJECT_OPERATOR in /in/BARW9 on line 3
Process exited with code 255.