3v4l.org

run code in 300+ PHP versions simultaneously
<?php function getClass(ReflectionType $type) { if ($type instanceof ReflectionNamedType) { if (!in_array($type->getName(), ['array', /* further predefined types */], true)) { return $type->getName(); } } return null; } function foo(array $array) {} $rf = new ReflectionFunction('foo'); $rp = $rf->getParameters()[0]; var_dump(isClass($rp->getType()));

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.30.0100.00818.95
8.5.20.0100.00817.08
8.5.10.0120.00616.76
8.5.00.0180.00820.15
8.4.180.0140.00819.84
8.4.170.0110.01023.85
8.4.160.0120.00923.73
8.4.150.0070.00616.89
8.4.140.0060.01518.05
8.4.130.0110.01017.76
8.4.120.0110.00920.77
8.4.110.0100.01020.59
8.4.100.0170.00317.90
8.4.90.0080.00120.75
8.4.80.0120.01018.86
8.4.70.0130.00619.03
8.4.60.0140.00618.58
8.4.50.0050.00418.75
8.4.40.0080.01217.88
8.4.30.0090.00920.55
8.4.20.0060.01317.87
8.4.10.0040.00419.80
8.3.300.0120.01120.70
8.3.290.0110.01020.57
8.3.280.0140.00618.35
8.3.270.0110.00916.60
8.3.260.0110.00916.66
8.3.250.0130.00518.89
8.3.240.0050.00316.52
8.3.230.0110.00816.60
8.3.220.0140.00719.02
8.3.210.0130.00516.63
8.3.200.0030.00816.55
8.3.190.0100.00916.92
8.3.180.0080.00618.80
8.3.170.0080.00616.96
8.3.160.0150.00318.26
8.3.150.0130.00616.63
8.3.140.0040.00417.15
8.3.130.0000.00618.37
8.3.120.0050.00320.62
8.3.110.0030.00620.94
8.3.100.0030.00724.06
8.3.90.0070.00726.77
8.3.80.0140.00019.36
8.3.70.0120.00616.75
8.3.60.0080.00818.68
8.3.50.0100.01016.55
8.3.40.0160.00318.97
8.3.30.0100.01019.02
8.3.20.0000.00824.18
8.3.10.0030.00524.66
8.3.00.0040.00426.16
8.2.300.0080.01118.75
8.2.290.0110.01120.44
8.2.280.0080.01018.55
8.2.270.0070.00717.38
8.2.260.0090.00916.88
8.2.250.0040.00416.81
8.2.240.0060.01217.29
8.2.230.0030.00522.58
8.2.220.0040.00437.54
8.2.210.0030.00626.77
8.2.200.0030.00618.88
8.2.190.0100.00718.66
8.2.180.0170.00325.92
8.2.170.0080.00818.95
8.2.160.0100.01022.96
8.2.150.0000.00725.66
8.2.140.0040.00424.66
8.2.130.0040.00426.16
8.2.120.0040.00426.35
8.2.110.0000.00819.22
8.2.100.0070.00417.71
8.2.90.0070.00020.55
8.2.80.0000.00820.36
8.2.70.0040.00417.93
8.2.60.0030.00518.03
8.2.50.0050.00318.10
8.2.40.0000.00921.05
8.2.30.0040.00419.31
8.2.20.0070.00018.05
8.2.10.0000.00719.12
8.2.00.0030.00519.31
8.1.340.0110.00821.63
8.1.330.0090.01116.53
8.1.320.0130.01016.13
8.1.310.0080.00018.48
8.1.300.0150.00018.09
8.1.290.0080.00430.84
8.1.280.0150.00325.92
8.1.270.0050.00323.99
8.1.260.0040.00428.09
8.1.250.0090.00028.09
8.1.240.0070.00323.86
8.1.230.0060.00620.89
8.1.220.0000.00917.75
8.1.210.0060.00318.82
8.1.200.0090.00317.35
8.1.190.0080.00017.22
8.1.180.0000.00818.10
8.1.170.0000.00818.50
8.1.160.0000.00718.79
8.1.150.0040.00418.89
8.1.140.0070.00018.79
8.1.130.0040.00420.09
8.1.120.0000.00717.35
8.1.110.0000.00817.39
8.1.100.0060.00317.42
8.1.90.0030.00517.31
8.1.80.0040.00417.43
8.1.70.0000.01017.41
8.1.60.0000.00817.43
8.1.50.0030.00517.53
8.1.40.0040.00417.57
8.1.30.0060.00317.68
8.1.20.0040.00417.61
8.1.10.0040.00417.60
8.1.00.0030.00617.35
8.0.300.0040.00419.77
8.0.290.0000.00816.75
8.0.280.0000.00818.30
8.0.270.0100.00016.71
8.0.260.0040.00420.04
8.0.250.0040.00416.92
8.0.240.0000.00816.85
8.0.230.0000.00717.03
8.0.220.0080.00016.89
8.0.210.0040.00416.92
8.0.200.0030.00716.83
8.0.190.0040.00416.96
8.0.180.0000.00716.93
8.0.170.0000.00816.96
8.0.160.0000.00716.96
8.0.150.0080.00016.78
8.0.140.0070.00016.74
8.0.130.0000.00513.39
8.0.120.0060.00316.90
8.0.110.0000.00816.96
8.0.100.0000.00716.86
8.0.90.0040.00416.92
8.0.80.0060.00916.88
8.0.70.0000.00816.85
8.0.60.0050.00316.89
8.0.50.0070.00016.75
8.0.30.0110.00716.93
8.0.20.0100.00716.95
8.0.10.0160.00517.23
8.0.00.0230.00417.04
7.4.330.0020.00215.55
7.4.320.0000.00616.55
7.4.300.0070.00016.53
7.4.290.0000.00816.46
7.4.280.0030.00516.50
7.4.270.0070.00016.61
7.4.260.0030.00313.23
7.4.250.0040.00416.56
7.4.240.0040.00416.54
7.4.230.0030.00316.59
7.4.220.0030.00316.64
7.4.210.0050.01016.51
7.4.200.0000.00916.41
7.4.160.0120.00616.02
7.4.150.0050.01016.32
7.4.140.0210.00316.43
7.4.130.0160.00816.47
7.4.120.0100.01216.54
7.4.110.0110.01116.70
7.4.100.0150.00716.46
7.4.90.0220.00016.54
7.4.80.0130.00916.57
7.4.70.0210.00316.41
7.4.60.0200.00316.53
7.4.50.0150.00616.40
7.4.40.0160.00916.43
7.4.30.0160.00616.49
7.4.20.0130.01016.41
7.4.10.0150.00816.61
7.4.00.0070.00716.50
7.3.330.0030.00316.23
7.3.320.0000.00613.23
7.3.310.0030.00316.40
7.3.300.0030.00316.24
7.3.290.0100.00816.38
7.3.270.0080.00816.09
7.3.260.0180.00916.39
7.3.250.0140.00916.49
7.3.240.0190.00316.48
7.3.230.0200.00516.34
7.3.220.0070.01916.34
7.3.210.0210.00616.46
7.3.200.0160.00716.38
7.3.190.0200.00316.29
7.3.180.0180.00916.23
7.3.170.0200.00516.61
7.3.160.0170.00616.48
7.3.150.0150.00916.42
7.3.140.0270.00416.41
7.3.130.0110.01316.43
7.3.120.0140.01116.45
7.3.110.0030.01216.40
7.3.100.0100.00516.36
7.3.90.0070.00716.43
7.3.80.0040.01116.25
7.3.70.0110.00416.41
7.3.60.0150.00016.09
7.3.50.0120.00316.32
7.3.40.0070.00716.15
7.3.30.0070.00716.37
7.3.20.0070.01016.39
7.3.10.0040.01116.24
7.3.00.0120.00416.41

preferences:
50 ms | 1404 KiB | 5 Q