3v4l.org

run code in 300+ PHP versions simultaneously
<?php namespace Http\Promise; interface Promise { public function then(callable $onFulfilled = null, ?callable $onRejected = null); } foreach ((new \ReflectionMethod(Promise::class, 'then'))->getParameters() as $p) { var_dump((string) $p); $t = $p->getType(); var_dump($t->getName()); var_dump($t->allowsNull()); var_dump((string) $t); echo "\n\n"; }
Output for git.master_jit, git.master, rfc.property-hooks
string(57) "Parameter #0 [ <optional> ?callable $onFulfilled = NULL ]" string(8) "callable" bool(true) string(9) "?callable" string(56) "Parameter #1 [ <optional> ?callable $onRejected = NULL ]" string(8) "callable" bool(true) string(9) "?callable"

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:
25.78 ms | 406 KiB | 5 Q