3v4l.org

run code in 300+ PHP versions simultaneously
<?php $input = [ [1, 2, 3, 4], [1, 2, 3, 4], [1, 2, 3, 4], ]; $keys = ['A', 'B', 'C', 'D']; $input = array_map(function($a) use ($keys) { return array_combine($keys, $a); }, $input); var_dump($input);
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/SE07Y
function name:  (null)
number of ops:  13
compiled vars:  !0 = $input, !1 = $keys
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   ASSIGN                                                   !0, <array>
    9     1        ASSIGN                                                   !1, <array>
   11     2        INIT_FCALL                                               'array_map'
          3        DECLARE_LAMBDA_FUNCTION                          ~4      [0]
          4        BIND_LEXICAL                                             ~4, !1
   13     5        SEND_VAL                                                 ~4
          6        SEND_VAR                                                 !0
   11     7        DO_ICALL                                         $5      
          8        ASSIGN                                                   !0, $5
   15     9        INIT_FCALL                                               'var_dump'
         10        SEND_VAR                                                 !0
         11        DO_ICALL                                                 
         12      > 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/SE07Y
function name:  {closure}
number of ops:  8
compiled vars:  !0 = $a, !1 = $keys
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   11     0  E >   RECV                                             !0      
          1        BIND_STATIC                                              !1
   12     2        INIT_FCALL                                               'array_combine'
          3        SEND_VAR                                                 !1
          4        SEND_VAR                                                 !0
          5        DO_ICALL                                         $2      
          6      > RETURN                                                   $2
   13     7*     > RETURN                                                   null

End of Dynamic Function 0

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
152.05 ms | 1012 KiB | 16 Q