3v4l.org

run code in 300+ PHP versions simultaneously
<?php function foo(bar $a = null, $b) { } $r = new ReflectionParameter('foo', 0); try { $r->getClass(); } catch (\Exception $e) { echo $e->getMessage(); } var_dump($r->isNullAllowed());

preferences:
45.67 ms | 402 KiB | 5 Q