3v4l.org

run code in 300+ PHP versions simultaneously
<?php class PHPlt84 { function bar(int $a = null, array $b) {} } class PHPlt84Child extends PHPlt84 { function bar(?int $a, array $b) {} } class PHPgte71 { function bar(?int $a, array $b) {} } class PHPgte71Child extends PHPgte71 { function bar(int $a = null, array $b) {} }
Output for 8.4.1 - 8.4.12
Deprecated: PHPlt84::bar(): Implicitly marking parameter $a as nullable is deprecated, the explicit nullable type must be used instead in /in/0qM7W on line 4 Deprecated: PHPgte71Child::bar(): Implicitly marking parameter $a as nullable is deprecated, the explicit nullable type must be used instead in /in/0qM7W on line 16
Output for 8.1.0 - 8.1.33, 8.2.0 - 8.2.29, 8.3.0 - 8.3.25

preferences:
45.97 ms | 407 KiB | 5 Q