3v4l.org

run code in 500+ PHP versions simultaneously
<?php $array = [ [ "referrer_id" => "usr157" ], [ "referrer_id" => "usr42" ] ]; $flatten = array_map(function($item) { return array_values($item)[0]; }, $array); var_dump($flatten);
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/6slrP
function name:  (null)
number of ops:  11
compiled vars:  !0 = $array, !1 = $flatten
line      #* E I O op                               fetch          ext  return  operands
-----------------------------------------------------------------------------------------
    3     0  E >   ASSIGN                                                       !0, <array>
   12     1        INIT_FCALL                                                   'array_map'
          2        DECLARE_LAMBDA_FUNCTION                              ~3      [0]
   14     3        SEND_VAL                                                     ~3
          4        SEND_VAR                                                     !0
   12     5        DO_ICALL                                             $4      
          6        ASSIGN                                                       !1, $4
   16     7        INIT_FCALL                                                   'var_dump'
          8        SEND_VAR                                                     !1
          9        DO_ICALL                                                     
         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/6slrP
function name:  {closure:/in/6slrP:12}
number of ops:  7
compiled vars:  !0 = $item
line      #* E I O op                               fetch          ext  return  operands
-----------------------------------------------------------------------------------------
   12     0  E >   RECV                                                 !0      
   13     1        INIT_FCALL                                                   'array_values'
          2        SEND_VAR                                                     !0
          3        DO_ICALL                                             $1      
          4        FETCH_DIM_R                                          ~2      $1, 0
          5      > RETURN                                                       ~2
   14     6*     > RETURN                                                       null

End of Dynamic Function 0

Generated using Vulcan Logic Dumper, using php 8.5.0


preferences:
168.55 ms | 1891 KiB | 16 Q