3v4l.org

run code in 500+ PHP versions simultaneously
<?php declare(strict_types=1); final class CreateStatementRequest { private ?DateTimeImmutable $startDate, $endDate; public function __construct( DateTimeImmutable $startDate = null, DateTimeImmutable $endDate = null ) { $this->startDate = $startDate; $this->endDate = $endDate; // error: Property CreateStatementRequest::$endDate (DateTimeImmutable) does not accept DateTimeImmutable|null. } public function hasFilterStartDate(): bool { return $this->startDate !== null; } public function getFilterStartDate(): DateTimeImmutable { if ($this->startDate === null) { throw new RuntimeException('The start date filter is not defined.'); } return $this->startDate; } public function hasFilterEndDate(): bool { return $this->endDate !== null; } public function getFilterEndDate(): DateTimeImmutable { if ($this->endDate === null) { // error: Strict comparison using === between DateTimeImmutable and null will always evaluate to false. throw new RuntimeException('The end date filter is not defined.'); } return $this->endDate; } } $ref = new \ReflectionClass(CreateStatementRequest::class); foreach ($ref->getProperties() as $refProperty) { var_dump($refProperty->getName()); $refType = $refProperty->getType(); var_dump($refType->getName()); var_dump($refType->allowsNull()); var_dump('---'); }

Here you find the average performance (time & memory) of each version. A grayed out version indicates it didn't complete successfully (based on exit-code).

VersionSystem time (s)User time (s)Memory (MiB)
8.5.80.0120.00516.85
8.5.70.0060.00218.46
8.5.60.0110.00516.86
8.5.50.0080.00916.63
8.5.30.0100.00717.29
8.5.20.0090.00919.52
8.5.10.0100.00718.77
8.5.00.0120.01620.07
8.4.230.0060.00319.64
8.4.220.0100.01421.42
8.4.210.0120.00919.67
8.4.180.0120.01119.76
8.4.170.0080.01223.82
8.4.160.0110.01123.08
8.4.150.0060.00616.85
8.4.140.0070.01517.70
8.4.130.0120.00918.91
8.4.120.0090.01024.09
8.4.110.0080.00522.61
8.4.100.0110.00717.68
8.4.90.0110.00917.57
8.4.80.0060.00317.98
8.4.70.0110.01019.80
8.4.60.0040.00419.00
8.4.50.0110.01118.84
8.4.40.0100.00619.24
8.4.30.0070.00320.38
8.4.20.0030.00620.66
8.4.10.0090.00017.50
8.3.320.0120.00818.45
8.3.310.0100.00918.47
8.3.300.0130.00818.83
8.3.290.0100.01020.86
8.3.280.0120.00818.51
8.3.270.0100.00916.49
8.3.260.0090.01116.57
8.3.250.0100.01018.95
8.3.240.0090.01017.05
8.3.230.0160.00516.50
8.3.220.0110.00820.86
8.3.210.0070.00116.63
8.3.200.0060.00316.69
8.3.190.0130.00717.05
8.3.180.0110.00719.05
8.3.170.0150.00418.92
8.3.160.0120.00617.34
8.3.150.0160.00319.11
8.3.140.0180.00016.60
8.3.130.0060.00316.41
8.3.120.0120.00318.93
8.3.110.0050.00320.94
8.3.100.0090.00016.61
8.3.90.0040.00426.77
8.3.80.0060.00319.36
8.3.70.0110.00418.43
8.3.60.0110.00718.18
8.3.50.0090.00523.59
8.3.40.0080.00818.66
8.3.30.0150.00018.78
8.3.20.0040.00420.80
8.3.10.0070.00421.66
8.3.00.0080.00023.61
8.2.320.0100.00917.98
8.2.310.0120.00818.06
8.2.300.0130.00720.20
8.2.290.0050.00320.51
8.2.280.0050.00218.20
8.2.270.0110.00718.85
8.2.260.0040.00416.77
8.2.250.0070.01116.46
8.2.240.0080.00017.44
8.2.230.0030.00722.58
8.2.220.0080.00024.06
8.2.210.0040.01426.77
8.2.200.0060.00318.88
8.2.190.0210.00018.29
8.2.180.0030.01616.38
8.2.170.0120.00322.96
8.2.160.0070.00720.43
8.2.150.0000.00824.18
8.2.140.0080.00024.66
8.2.130.0000.00826.16
8.2.120.0080.00026.16
8.2.110.0060.00319.13
8.2.100.0000.01117.91
8.2.90.0080.00017.63
8.2.80.0040.00718.84
8.2.70.0000.00917.50
8.2.60.0080.00018.03
8.2.50.0000.00818.10
8.2.40.0000.00719.48
8.2.30.0040.00419.19
8.2.20.0040.00418.15
8.2.10.0040.00419.28
8.2.00.0040.00419.22
8.1.340.0050.00417.55
8.1.330.0040.00517.02
8.1.320.0130.00717.88
8.1.310.0030.00618.41
8.1.300.0090.00016.35
8.1.290.0040.00430.84
8.1.280.0140.00725.92
8.1.270.0040.00422.20
8.1.260.0080.00026.35
8.1.250.0080.00028.09
8.1.240.0060.00622.04
8.1.230.0060.00620.96
8.1.220.0050.00317.74
8.1.210.0030.00518.77
8.1.200.0050.00317.23
8.1.190.0080.00017.23
8.1.180.0050.00318.83
8.1.170.0000.00918.46
8.1.160.0000.00719.00
8.1.150.0000.00719.05
8.1.140.0070.00020.84
8.1.130.0030.00320.20
8.1.120.0030.00517.53
8.1.110.0070.00017.52
8.1.100.0000.00817.49
8.1.90.0070.00017.48
8.1.80.0030.00617.49
8.1.70.0040.00417.44
8.1.60.0030.00617.52
8.1.50.0000.00817.58
8.1.40.0050.00317.55
8.1.30.0000.00817.61
8.1.20.0040.00417.57
8.1.10.0000.00717.51
8.1.00.0000.00817.52
8.0.300.0000.00718.77
8.0.290.0070.00016.63
8.0.280.0000.00718.43
8.0.270.0050.00318.62
8.0.260.0000.00720.15
8.0.250.0030.00516.97
8.0.240.0000.00616.99
8.0.230.0000.00716.98
8.0.220.0030.00316.86
8.0.210.0000.00616.94
8.0.200.0030.00317.02
8.0.190.0000.00717.00
8.0.180.0040.00416.93
8.0.170.0000.00917.00
8.0.160.0040.00416.98
8.0.150.0000.00816.91
8.0.140.0050.00316.82
8.0.130.0030.00313.31
8.0.120.0000.00716.90
8.0.110.0080.00016.79
8.0.100.0040.00416.81
8.0.90.0040.00416.95
8.0.80.0040.01116.88
8.0.70.0040.00416.77
8.0.60.0030.00616.80
8.0.50.0000.00716.80
8.0.30.0040.01317.11
8.0.20.0170.00317.32
8.0.10.0040.00416.95
8.0.00.0090.01116.76
7.4.330.0060.00016.85
7.4.320.0000.00616.54
7.4.300.0030.00316.64
7.4.290.0070.00016.59
7.4.280.0050.00316.62
7.4.270.0000.00716.44
7.4.260.0050.00013.25
7.4.250.0040.00416.57
7.4.240.0000.00816.54
7.4.230.0000.00816.61
7.4.220.0030.00316.58
7.4.210.0070.00916.50
7.4.200.0030.00316.44
7.4.130.0170.00616.47
7.4.120.0080.01116.30
7.4.110.0030.01416.53
7.4.100.0060.01116.66
7.4.90.0070.01016.53
7.4.80.0120.00619.39
7.4.70.0080.00816.43
7.4.60.0040.01116.49
7.4.50.0090.00616.38
7.4.40.0140.00916.48
7.4.30.0040.01416.46
7.4.20.0060.00916.65
7.4.10.0120.00816.42
7.4.00.0090.01216.52
7.3.330.0030.00316.13
7.3.320.0050.00013.23
7.3.310.0060.00016.23
7.3.300.0050.00216.16
7.3.290.0070.00916.16
7.3.260.0090.00916.30
7.3.240.0090.01016.35
7.3.230.0140.00316.37
7.3.210.0060.01016.30
7.3.200.0100.00716.19
7.3.190.0030.01416.30
7.3.180.0000.01616.06
7.3.170.0120.00416.20
7.3.160.0170.00016.26
7.3.150.0080.01216.19
7.3.140.0130.00316.29
7.3.130.0090.01216.05
7.3.120.0110.00816.26
7.3.110.0110.01016.15
7.3.100.0110.01016.18
7.3.90.0160.00316.33
7.3.80.0120.00816.11
7.3.70.0120.00615.96
7.3.60.0130.00316.01
7.3.50.0020.01416.12
7.3.40.0080.01116.09
7.3.30.0090.00816.24
7.3.20.0120.00616.08
7.3.10.0090.00816.26
7.3.00.0070.01016.15
7.2.330.0180.00616.45
7.2.320.0060.01116.23
7.2.310.0080.00816.47
7.2.300.0190.00316.29
7.2.290.0070.01316.44
7.2.280.0150.00616.07
7.2.270.0030.01316.12
7.2.260.0100.01116.37
7.2.250.0100.01016.27
7.2.240.0100.00716.25
7.2.230.0060.01016.31
7.2.220.0090.00616.31
7.2.210.0060.01316.23
7.2.200.0090.00716.17
7.2.190.0090.00816.33
7.2.180.0060.01016.20
7.2.170.0060.01016.31
7.2.160.0080.01116.27
7.2.150.0110.00816.33
7.2.140.0100.00716.40
7.2.130.0060.01216.33
7.2.120.0100.00916.41
7.2.110.0240.00616.41
7.2.100.0070.01116.35
7.2.90.0090.00916.29
7.2.80.0090.00716.41
7.2.70.0060.01016.15
7.2.60.0050.01116.18
7.2.50.0070.01016.32
7.2.40.0030.01216.30
7.2.30.0090.00716.50
7.2.20.0130.00516.29
7.2.10.0110.00816.30
7.2.00.0070.01216.25

preferences:
63.58 ms | 1565 KiB | 5 Q