3v4l.org

run code in 300+ PHP versions simultaneously
<?php class DebugRII extends RecursiveIteratorIterator { public function beginChildren() { echo __METHOD__, "\n"; } public function beginIteration() { echo __METHOD__, "\n"; } public function callGetChildren() { echo __METHOD__, "\n"; } public function callHasChildren() { echo __METHOD__, "\n"; } public function endChildren() { echo __METHOD__, "\n"; } public function endIteration() { echo __METHOD__, "\n"; } } $array = array("A","B","C"); $iterator = new DebugRII(new RecursiveArrayIterator($array)); while ($iterator->valid()) { echo $iterator->current(), "\n"; $iterator->next(); }
Output for git.master, git.master_jit, rfc.property-hooks
Deprecated: Return type of DebugRII::beginIteration() should either be compatible with RecursiveIteratorIterator::beginIteration(): void, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in /in/nXsfY on line 4 Deprecated: Return type of DebugRII::endIteration() should either be compatible with RecursiveIteratorIterator::endIteration(): void, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in /in/nXsfY on line 8 Deprecated: Return type of DebugRII::callHasChildren() should either be compatible with RecursiveIteratorIterator::callHasChildren(): bool, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in /in/nXsfY on line 6 Deprecated: Return type of DebugRII::callGetChildren() should either be compatible with RecursiveIteratorIterator::callGetChildren(): ?RecursiveIterator, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in /in/nXsfY on line 5 Deprecated: Return type of DebugRII::beginChildren() should either be compatible with RecursiveIteratorIterator::beginChildren(): void, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in /in/nXsfY on line 3 Deprecated: Return type of DebugRII::endChildren() should either be compatible with RecursiveIteratorIterator::endChildren(): void, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in /in/nXsfY on line 7 A DebugRII::callHasChildren A DebugRII::callHasChildren B DebugRII::callHasChildren C

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:
33.03 ms | 405 KiB | 8 Q