3v4l.org

run code in 300+ PHP versions simultaneously
<?php $data = [ ["username" => "erick", "location" => ["singapore"], "province" => ["jatim"]], ["username" => "thomas", "location" => ["ukraina"], "province" => ["anonymouse"]] ]; var_export( array_map( fn($arr) => array_map( fn($v) => ((array) $v)[0], $arr ), $data ) );
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/UuZWJ
function name:  (null)
number of ops:  11
compiled vars:  !0 = $data, !1 = $v
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   ASSIGN                                                   !0, <array>
    8     1        INIT_FCALL                                               'var_export'
    9     2        INIT_FCALL                                               'array_map'
   10     3        DECLARE_LAMBDA_FUNCTION                          ~3      [0]
          4        BIND_LEXICAL                                             ~3, !1
   14     5        SEND_VAL                                                 ~3
   15     6        SEND_VAR                                                 !0
    9     7        DO_ICALL                                         $4      
   15     8        SEND_VAR                                                 $4
    8     9        DO_ICALL                                                 
   17    10      > RETURN                                                   1


Dynamic Functions:
Dynamic Function 0
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/UuZWJ
function name:  {closure}
number of ops:  9
compiled vars:  !0 = $arr, !1 = $v
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   10     0  E >   RECV                                             !0      
          1        BIND_STATIC                                              !1
   11     2        INIT_FCALL                                               'array_map'
   12     3        DECLARE_LAMBDA_FUNCTION                          ~2      [0]
          4        SEND_VAL                                                 ~2
   13     5        SEND_VAR                                                 !0
   11     6        DO_ICALL                                         $3      
   13     7      > RETURN                                                   $3
   14     8*     > RETURN                                                   null


Dynamic Functions:
Dynamic Function 0
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/UuZWJ
function name:  {closure}
number of ops:  5
compiled vars:  !0 = $v
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   12     0  E >   RECV                                             !0      
          1        CAST                                          7  ~1      !0
          2        FETCH_DIM_R                                      ~2      ~1, 0
          3      > RETURN                                                   ~2
          4*     > RETURN                                                   null

End of Dynamic Function 0

End of Dynamic Function 0

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
151.07 ms | 1012 KiB | 15 Q