3v4l.org

run code in 300+ PHP versions simultaneously
<?php $array = [1, 2, 3, 4]; $array2 = [5, 6, 7, 8]; $function = function($array) { var_dump($array); die(); }; var_dump(array_map($function, $array));
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/ZgQQ2
function name:  (null)
number of ops:  12
compiled vars:  !0 = $array, !1 = $array2, !2 = $function
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   ASSIGN                                                   !0, <array>
    4     1        ASSIGN                                                   !1, <array>
    6     2        DECLARE_LAMBDA_FUNCTION                                  '%00%7Bclosure%7D%2Fin%2FZgQQ2%3A6%240'
          3        ASSIGN                                                   !2, ~5
   11     4        INIT_FCALL                                               'var_dump'
          5        INIT_FCALL                                               'array_map'
          6        SEND_VAR                                                 !2
          7        SEND_VAR                                                 !0
          8        DO_ICALL                                         $7      
          9        SEND_VAR                                                 $7
         10        DO_ICALL                                                 
         11      > RETURN                                                   1

Function %00%7Bclosure%7D%2Fin%2FZgQQ2%3A6%240:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 79) Position 1 = -2
filename:       /in/ZgQQ2
function name:  {closure}
number of ops:  6
compiled vars:  !0 = $array
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    6     0  E >   RECV                                             !0      
    7     1        INIT_FCALL                                               'var_dump'
          2        SEND_VAR                                                 !0
          3        DO_ICALL                                                 
    8     4      > EXIT                                                     
    9     5*     > RETURN                                                   null

End of function %00%7Bclosure%7D%2Fin%2FZgQQ2%3A6%240

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
190.4 ms | 1395 KiB | 17 Q