3v4l.org

run code in 300+ PHP versions simultaneously
<?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; }
Output for git.master, git.master_jit, rfc.property-hooks
$message isOptional : true isDefaultValueAvailable : true getDefaultValue : '' $code isOptional : true isDefaultValueAvailable : true getDefaultValue : 0 $previous isOptional : true isDefaultValueAvailable : true getDefaultValue : NULL

This tab shows result from various feature-branches currently under review by the php developers. Contact me to have additional branches featured.

Active branches

Archived branches

Once feature-branches are merged or declined, they are no longer available. Their functionality (when merged) can be viewed from the main output page


preferences:
69.95 ms | 402 KiB | 8 Q