3v4l.org

run code in 300+ PHP versions simultaneously
<?php function print_options($opts, $parents){ global $combos; global $md5s; if($opts){ foreach($opts as $level) { if($parents){ print_options($level[1], array($parents, $level[0])); } else { print_options($level[1], $level[0]);} } } else { if(!is_array($parents)) { $parents = array($parents); } $newarray = array(); //array_walk($parents, 'flatten_array', $newarray); array_walk_recursive($parents, function($a) use (&$newarray) { $newarray[] = $a; }); $combos[] = $newarray; $md5s[] = hashOptions($newarray); return $newarray; } }
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/vIYo3
function name:  (null)
number of ops:  1
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   28     0  E > > RETURN                                                   1

Function print_options:
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 43) Position 1 = 5, Position 2 = 29
Branch analysis from position: 5
2 jumps found. (Code = 77) Position 1 = 6, Position 2 = 27
Branch analysis from position: 6
2 jumps found. (Code = 78) Position 1 = 7, Position 2 = 27
Branch analysis from position: 7
2 jumps found. (Code = 43) Position 1 = 8, Position 2 = 18
Branch analysis from position: 8
1 jumps found. (Code = 42) Position 1 = 26
Branch analysis from position: 26
1 jumps found. (Code = 42) Position 1 = 6
Branch analysis from position: 6
Branch analysis from position: 18
1 jumps found. (Code = 42) Position 1 = 6
Branch analysis from position: 6
Branch analysis from position: 27
1 jumps found. (Code = 42) Position 1 = 49
Branch analysis from position: 49
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 27
Branch analysis from position: 29
2 jumps found. (Code = 43) Position 1 = 32, Position 2 = 34
Branch analysis from position: 32
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 34
filename:       /in/vIYo3
function name:  print_options
number of ops:  50
compiled vars:  !0 = $opts, !1 = $parents, !2 = $combos, !3 = $md5s, !4 = $level, !5 = $newarray
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   RECV                                             !0      
          1        RECV                                             !1      
    4     2        BIND_GLOBAL                                              !2, 'combos'
    5     3        BIND_GLOBAL                                              !3, 'md5s'
    6     4      > JMPZ                                                     !0, ->29
    7     5    > > FE_RESET_R                                       $6      !0, ->27
          6    > > FE_FETCH_R                                               $6, !4, ->27
    9     7    > > JMPZ                                                     !1, ->18
   10     8    >   INIT_FCALL_BY_NAME                                       'print_options'
          9        CHECK_FUNC_ARG                                           
         10        FETCH_DIM_FUNC_ARG                               $7      !4, 1
         11        SEND_FUNC_ARG                                            $7
         12        INIT_ARRAY                                       ~8      !1
         13        FETCH_DIM_R                                      ~9      !4, 0
         14        ADD_ARRAY_ELEMENT                                ~8      ~9
         15        SEND_VAL_EX                                              ~8
         16        DO_FCALL                                      0          
         17      > JMP                                                      ->26
   12    18    >   INIT_FCALL_BY_NAME                                       'print_options'
         19        CHECK_FUNC_ARG                                           
         20        FETCH_DIM_FUNC_ARG                               $11     !4, 1
         21        SEND_FUNC_ARG                                            $11
         22        CHECK_FUNC_ARG                                           
         23        FETCH_DIM_FUNC_ARG                               $12     !4, 0
         24        SEND_FUNC_ARG                                            $12
         25        DO_FCALL                                      0          
    7    26    > > JMP                                                      ->6
         27    >   FE_FREE                                                  $6
         28      > JMP                                                      ->49
   15    29    >   TYPE_CHECK                                  128  ~14     !1
         30        BOOL_NOT                                         ~15     ~14
         31      > JMPZ                                                     ~15, ->34
   17    32    >   INIT_ARRAY                                       ~16     !1
         33        ASSIGN                                                   !1, ~16
   19    34    >   ASSIGN                                                   !5, <array>
   22    35        INIT_FCALL                                               'array_walk_recursive'
         36        SEND_REF                                                 !1
         37        DECLARE_LAMBDA_FUNCTION                                  '%00%7Bclosure%7D%2Fin%2FvIYo3%3A22%240'
         38        BIND_LEXICAL                                             ~19, !5
         39        SEND_VAL                                                 ~19
         40        DO_ICALL                                                 
   24    41        ASSIGN_DIM                                               !2
         42        OP_DATA                                                  !5
   25    43        INIT_FCALL_BY_NAME                                       'hashOptions'
         44        SEND_VAR_EX                                              !5
         45        DO_FCALL                                      0  $23     
         46        ASSIGN_DIM                                               !3
         47        OP_DATA                                                  $23
   26    48      > RETURN                                                   !5
   28    49    > > RETURN                                                   null

End of function print_options

Function %00%7Bclosure%7D%2Fin%2FvIYo3%3A22%240:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/vIYo3
function name:  {closure}
number of ops:  5
compiled vars:  !0 = $a, !1 = $newarray
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   22     0  E >   RECV                                             !0      
          1        BIND_STATIC                                              !1
          2        ASSIGN_DIM                                               !1
          3        OP_DATA                                                  !0
          4      > RETURN                                                   null

End of function %00%7Bclosure%7D%2Fin%2FvIYo3%3A22%240

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
150.81 ms | 1400 KiB | 15 Q