3v4l.org

run code in 300+ PHP versions simultaneously
<?php class parent1 { public function __construct($param) { var_dump($param); } } class child extends parent1 { public function method() { //而且我在这里直接return居然不生效,代码直接从 //parent::__construct($param);开始执行,也就是说前面的代码没有执行,问题应该就在这里,不理解为什么不执行。 $param = 123; parent::__construct($param); } } (new child(1))->method();

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.4.140.0090.01117.33
8.4.130.0110.00917.57
8.4.120.0070.01322.50
8.4.110.0100.01022.48
8.4.100.0150.00618.71
8.4.90.0070.00920.68
8.4.80.0090.01118.98
8.4.70.0100.01118.68
8.4.60.0140.00818.63
8.4.50.0120.00919.23
8.4.40.0160.00321.95
8.4.30.0030.01619.01
8.4.20.0130.00720.81
8.4.10.0090.00023.66
8.3.270.0120.01016.63
8.3.260.0140.00616.47
8.3.250.0110.00818.94
8.3.240.0090.01016.43
8.3.230.0110.00816.36
8.3.220.0100.00719.02
8.3.210.0110.00316.55
8.3.200.0070.00416.62
8.3.190.0070.00216.70
8.3.180.0090.00618.81
8.3.170.0070.01118.88
8.3.160.0090.00922.63
8.3.150.0110.00718.93
8.3.140.0120.00317.06
8.3.130.0030.00618.59
8.3.120.0120.00320.51
8.3.110.0030.00720.94
8.3.100.0100.00624.06
8.3.90.0120.00626.77
8.3.80.0000.01116.38
8.3.70.0080.00816.58
8.3.60.0180.00018.30
8.3.50.0120.00316.50
8.3.40.0060.00919.79
8.3.30.0090.00618.54
8.3.20.0000.00724.18
8.3.10.0030.00624.66
8.3.00.0040.00426.16
8.2.290.0100.00820.21
8.2.280.0070.00818.38
8.2.270.0070.01021.98
8.2.260.0080.00019.04
8.2.250.0050.00316.39
8.2.240.0080.00017.16
8.2.230.0110.00722.58
8.2.220.0000.00837.54
8.2.210.0000.00826.77
8.2.200.0030.00616.63
8.2.190.0140.00716.58
8.2.180.0070.01416.63
8.2.170.0220.00018.83
8.2.160.0140.00022.96
8.2.150.0080.00025.66
8.2.140.0040.00424.66
8.2.130.0000.00726.16
8.2.120.0080.00019.65
8.2.110.0030.00621.00
8.2.100.0040.00817.78
8.2.90.0080.00320.55
8.2.80.0000.00817.97
8.2.70.0050.00517.93
8.2.60.0040.01017.36
8.2.50.0110.00718.38
8.2.40.0070.00518.38
8.2.30.0120.00418.57
8.2.20.0130.00318.45
8.2.10.0130.00518.26
8.2.00.0090.00818.32
8.1.330.0090.01016.47
8.1.320.0120.00616.34
8.1.310.0090.00916.85
8.1.300.0000.00918.29
8.1.290.0090.00030.84
8.1.280.0130.00625.92
8.1.270.0130.01020.41
8.1.260.0070.00326.35
8.1.250.0040.00428.09
8.1.240.0140.00720.61
8.1.230.0080.00420.83
8.1.220.0040.00417.74
8.1.210.0040.00418.79
8.1.200.0000.00817.22
8.1.190.0050.00317.16
8.1.180.0070.00518.26
8.1.170.0100.00618.13
8.1.160.0100.00718.31
8.1.150.0080.00818.20
8.1.140.0140.00418.32
8.1.130.0090.00818.25
8.1.120.0150.00418.26
8.1.110.0130.00418.31
8.1.100.0140.00318.32
8.1.90.0110.00618.31
8.1.80.0100.00718.32
8.1.70.0070.01118.45
8.1.60.0190.00218.38
8.1.50.0140.00418.45
8.1.40.0110.01018.32
8.1.30.0180.00418.38
8.1.20.0160.00318.38
8.1.10.0130.00618.13
8.1.00.0090.00918.32
8.0.300.0050.00219.86
8.0.290.0030.00616.63
8.0.280.0110.00518.02
8.0.270.0130.00418.02
8.0.260.0090.00718.02
8.0.250.0130.00518.06
8.0.240.0110.00618.02
8.0.230.0150.00218.02
8.0.220.0120.00518.02
8.0.210.0130.00518.02
8.0.200.0130.00518.07
8.0.190.0110.00618.02
8.0.180.0140.00318.02
8.0.170.0090.00718.02
8.0.160.0120.00618.02
8.0.150.0090.00718.02
8.0.140.0100.00718.02
8.0.130.0140.00218.02
8.0.120.0150.00318.02
8.0.110.0120.00618.02
8.0.100.0130.00418.02
8.0.90.0120.00418.02
8.0.80.0130.00418.02
8.0.70.0100.00618.02
8.0.60.0140.00418.02
8.0.50.0120.00418.02
8.0.30.0090.00718.02
8.0.20.0090.00818.02
8.0.10.0130.00418.02

preferences:
33.59 ms | 403 KiB | 5 Q