3v4l.org

run code in 300+ PHP versions simultaneously
<?php $a = array(); $a[] = array('a' => 1); $a[] = array('a' => 2); $a[] = array('a' => 3); $column = 'a'; $res = array_map(function ($item) use ($column) {return is_object($item) ? $item->{$column} : $item[$column]; }, $a); var_dump($res);
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/gpfCu
function name:  (null)
number of ops:  19
compiled vars:  !0 = $a, !1 = $column, !2 = $res
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    2     0  E >   ASSIGN                                                   !0, <array>
    3     1        ASSIGN_DIM                                               !0
          2        OP_DATA                                                  <array>
    4     3        ASSIGN_DIM                                               !0
          4        OP_DATA                                                  <array>
    5     5        ASSIGN_DIM                                               !0
          6        OP_DATA                                                  <array>
    7     7        ASSIGN                                                   !1, 'a'
    8     8        INIT_FCALL                                               'array_map'
          9        DECLARE_LAMBDA_FUNCTION                                  '%00%7Bclosure%7D%2Fin%2FgpfCu%3A8%240'
         10        BIND_LEXICAL                                             ~8, !1
         11        SEND_VAL                                                 ~8
         12        SEND_VAR                                                 !0
         13        DO_ICALL                                         $9      
         14        ASSIGN                                                   !2, $9
    9    15        INIT_FCALL                                               'var_dump'
         16        SEND_VAR                                                 !2
         17        DO_ICALL                                                 
         18      > RETURN                                                   1

Function %00%7Bclosure%7D%2Fin%2FgpfCu%3A8%240:
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 43) Position 1 = 4, Position 2 = 7
Branch analysis from position: 4
1 jumps found. (Code = 42) Position 1 = 9
Branch analysis from position: 9
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 7
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/gpfCu
function name:  {closure}
number of ops:  11
compiled vars:  !0 = $item, !1 = $column
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    8     0  E >   RECV                                             !0      
          1        BIND_STATIC                                              !1
          2        TYPE_CHECK                                  256          !0
          3      > JMPZ                                                     ~2, ->7
          4    >   FETCH_OBJ_R                                      ~3      !0, !1
          5        QM_ASSIGN                                        ~4      ~3
          6      > JMP                                                      ->9
          7    >   FETCH_DIM_R                                      ~5      !0, !1
          8        QM_ASSIGN                                        ~4      ~5
          9    > > RETURN                                                   ~4
         10*     > RETURN                                                   null

End of function %00%7Bclosure%7D%2Fin%2FgpfCu%3A8%240

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
151.31 ms | 1396 KiB | 17 Q