3v4l.org

run code in 300+ PHP versions simultaneously
<?php $ar = array('a' => 'b'); function cb($v) { return $v; } print_r(array_map('cb', $ar)); print_r(array_map('cb', $ar, array_keys($ar)));
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/25b74
function name:  (null)
number of ops:  20
compiled vars:  !0 = $ar
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   ASSIGN                                                   !0, <array>
    5     1        INIT_FCALL                                               'print_r'
          2        INIT_FCALL                                               'array_map'
          3        SEND_VAL                                                 'cb'
          4        SEND_VAR                                                 !0
          5        DO_ICALL                                         $2      
          6        SEND_VAR                                                 $2
          7        DO_ICALL                                                 
    6     8        INIT_FCALL                                               'print_r'
          9        INIT_FCALL                                               'array_map'
         10        SEND_VAL                                                 'cb'
         11        SEND_VAR                                                 !0
         12        INIT_FCALL                                               'array_keys'
         13        SEND_VAR                                                 !0
         14        DO_ICALL                                         $4      
         15        SEND_VAR                                                 $4
         16        DO_ICALL                                         $5      
         17        SEND_VAR                                                 $5
         18        DO_ICALL                                                 
         19      > RETURN                                                   1

Function cb:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/25b74
function name:  cb
number of ops:  3
compiled vars:  !0 = $v
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    4     0  E >   RECV                                             !0      
          1      > RETURN                                                   !0
          2*     > RETURN                                                   null

End of function cb

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
172.83 ms | 1395 KiB | 19 Q