3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php $rc = new ReflectionClass('Exception'); $rps = $rc->getConstructor()->getParameters(); foreach ($rps as $rp) { echo '$', $rp->getName(), PHP_EOL; echo "\t isOptional : ", var_export($rp->isOptional(), true), PHP_EOL; echo "\t isDefaultValueAvailable : ", var_export($rp->isDefaultValueAvailable(), true), PHP_EOL; if ($rp->isDefaultValueAvailable()) { echo "\t getDefaultValue : ", var_export($rp->getDefaultValue(), true), PHP_EOL; } echo PHP_EOL, PHP_EOL; }
based on nXQ38