3v4l.org

run code in 300+ PHP versions simultaneously
<?php function map(?callable $transformer, iterable ... $inputs): iterable { // for now I just care how named parameters work var_dump($inputs); return \array_map($transformer, ...$inputs); } map(transformer: null, inputs: [[1, 2], [3, 4]]);
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/sSVTZ
function name:  (null)
number of ops:  6
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   10     0  E >   INIT_FCALL                                               'map'
          1        SEND_VAL                                                 null
          2        SEND_VAL_EX                                              <array>, 'inputs'
          3        CHECK_UNDEF_ARGS                                         
          4        DO_FCALL                                      1          
          5      > RETURN                                                   1

Function map:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/sSVTZ
function name:  map
number of ops:  14
compiled vars:  !0 = $transformer, !1 = $inputs
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   RECV                                             !0      
          1        RECV_VARIADIC                                    !1      
    5     2        INIT_FCALL                                               'var_dump'
          3        SEND_VAR                                                 !1
          4        DO_ICALL                                                 
    6     5        INIT_FCALL                                               'array_map'
          6        SEND_VAR                                                 !0
          7        SEND_UNPACK                                              !1
          8        CHECK_UNDEF_ARGS                                         
          9        DO_ICALL                                         $3      
         10        VERIFY_RETURN_TYPE                                       $3
         11      > RETURN                                                   $3
    7    12*       VERIFY_RETURN_TYPE                                       
         13*     > RETURN                                                   null

End of function map

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
148.45 ms | 1013 KiB | 16 Q