3v4l.org

run code in 300+ PHP versions simultaneously
<?php $arr = [0,1,[0,1,[0,1]]]; $dir = new RecursiveArrayIterator($arr); $it = new RecursiveCallbackFilterIterator($dir, function(){return true;}); var_dump($it->getChildren());
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/afPL7
function name:  (null)
number of ops:  17
compiled vars:  !0 = $arr, !1 = $dir, !2 = $it
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    2     0  E >   ASSIGN                                                   !0, <array>
    3     1        NEW                                              $4      'RecursiveArrayIterator'
          2        SEND_VAR_EX                                              !0
          3        DO_FCALL                                      0          
          4        ASSIGN                                                   !1, $4
    5     5        NEW                                              $7      'RecursiveCallbackFilterIterator'
          6        SEND_VAR_EX                                              !1
          7        DECLARE_LAMBDA_FUNCTION                                  '%00%7Bclosure%7D%2Fin%2FafPL7%3A5%240'
          8        SEND_VAL_EX                                              ~8
          9        DO_FCALL                                      0          
         10        ASSIGN                                                   !2, $7
    7    11        INIT_FCALL                                               'var_dump'
         12        INIT_METHOD_CALL                                         !2, 'getChildren'
         13        DO_FCALL                                      0  $11     
         14        SEND_VAR                                                 $11
         15        DO_ICALL                                                 
         16      > RETURN                                                   1

Function %00%7Bclosure%7D%2Fin%2FafPL7%3A5%240:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/afPL7
function name:  {closure}
number of ops:  2
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    5     0  E > > RETURN                                                   <true>
          1*     > RETURN                                                   null

End of function %00%7Bclosure%7D%2Fin%2FafPL7%3A5%240

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
174.29 ms | 1395 KiB | 15 Q