3v4l.org

run code in 300+ PHP versions simultaneously
<?php class A {} class B extends A {} function asd(callable(B, callable(B)) $cb) { $cb(new B, function (B $b) { }); } // first argument can be relaxed, but the one inside callable can not, otherwise when `asd()` // will try to call $cba, it should be able to pass it `callable(B)` (as it was declared in `asd()` signature) // But now that we relaxed requirement in this anon function, `asd()` will have to pass a function with relaxed req. too asd(function (A $a, callable(A) $cba) { });

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)
5.4.390.0630.05018.96
5.4.380.0100.06018.69
5.4.370.0130.06018.66
5.4.360.0170.05018.59
5.4.350.0100.06018.75
5.4.340.0200.04718.55
5.4.320.0100.06018.72
5.4.310.0130.06018.47
5.4.300.0200.07318.70
5.4.290.0230.06718.60
5.4.280.0070.06318.70
5.4.270.0200.05018.63
5.4.260.0100.06018.58
5.4.250.0200.07318.70
5.4.240.0130.06318.64
5.4.230.0070.06318.52
5.4.220.0130.05718.54
5.4.210.0130.05718.69
5.4.200.0230.04316.59
5.4.190.0100.05718.67
5.4.180.0170.05018.76
5.4.170.0070.06718.70
5.4.160.0230.04318.47
5.4.150.0100.05718.59
5.4.140.0100.06016.23
5.4.130.0130.04716.19
5.4.120.0070.05716.46
5.4.110.0170.04716.25
5.4.100.0200.06016.21
5.4.90.0200.04716.28
5.4.80.0200.05716.21
5.4.70.0200.04316.42
5.4.60.0170.07016.22
5.4.50.0300.05316.15
5.4.40.0070.07716.29
5.4.30.0100.07016.38
5.4.20.0270.04316.39
5.4.10.0170.04716.29
5.4.00.0100.05315.69
5.3.290.0200.05014.66
5.3.280.0200.05314.72
5.3.270.0170.05014.63
5.3.260.0130.05014.65
5.3.250.0300.05314.73
5.3.240.0070.05714.73
5.3.230.0270.06014.79
5.3.220.0270.06714.58
5.3.210.0070.06014.67
5.3.200.0130.05714.81
5.3.190.0270.04314.66
5.3.180.0170.06014.58
5.3.170.0130.06014.62
5.3.160.0230.04714.66
5.3.150.0070.07314.59
5.3.140.0200.06714.61
5.3.130.0170.05314.53
5.3.120.0130.05714.68
5.3.110.0170.05314.60
5.3.100.0100.05714.04
5.3.90.0130.06314.08
5.3.80.0030.05714.07
5.3.70.0000.06314.14
5.3.60.0130.05014.05
5.3.50.0130.05313.99
5.3.40.0130.04714.07
5.3.30.0130.04713.96
5.3.20.0100.05013.74
5.3.10.0170.04713.75
5.3.00.0070.05713.66
5.2.170.0070.05011.37
5.2.160.0030.05011.35
5.2.150.0100.04311.27
5.2.140.0130.05011.14
5.2.130.0030.04711.14
5.2.120.0170.03311.21
5.2.110.0100.04011.20
5.2.100.0070.04311.05
5.2.90.0230.04311.15
5.2.80.0200.05011.21
5.2.70.0030.06311.12
5.2.60.0170.04011.08
5.2.50.0070.04711.11
5.2.40.0070.05711.06
5.2.30.0130.05011.17
5.2.20.0130.04711.18
5.2.10.0130.05011.06
5.2.00.0130.05310.71
5.1.60.0100.04310.08
5.1.50.0000.05310.03
5.1.40.0100.03310.00
5.1.30.0070.05310.52
5.1.20.0100.05010.41
5.1.10.0070.04710.25
5.1.00.0100.03310.18
5.0.50.0070.0278.63
5.0.40.0070.0278.44
5.0.30.0070.0438.32
5.0.20.0100.0278.24
5.0.10.0130.0308.24
5.0.00.0030.0538.34
4.4.90.0030.0336.45
4.4.80.0070.0306.45
4.4.70.0100.0176.45
4.4.60.0130.0176.45
4.4.50.0070.0206.45
4.4.40.0070.0336.45
4.4.30.0070.0236.45
4.4.20.0030.0306.45
4.4.10.0030.0306.45
4.4.00.0030.0476.45
4.3.110.0070.0276.45
4.3.100.0030.0306.45
4.3.90.0030.0306.45
4.3.80.0030.0406.45
4.3.70.0000.0306.45
4.3.60.0070.0276.45
4.3.50.0030.0236.45
4.3.40.0100.0336.45
4.3.30.0000.0306.45
4.3.20.0030.0236.45
4.3.10.0030.0236.45
4.3.00.0030.0207.22

preferences:
154.23 ms | 1592 KiB | 7 Q