3v4l.org

run code in 300+ PHP versions simultaneously
<?php function lib_function($a1, $a2){ var_dump($a1, $a2); } function i_evaluate_my_arguments(){ $evaluated_args = array_map(function($a){ return $a(); }, func_get_args()); call_user_func_array('lib_function', $evaluated_args); } call_user_func_array( 'i_evaluate_my_arguments', array( function(){ return 'foo'; }, function(){ return 'baz'; } ) );
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/VurX8
function name:  (null)
number of ops:  9
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   13     0  E >   INIT_FCALL                                               'i_evaluate_my_arguments'
   16     1        DECLARE_LAMBDA_FUNCTION                                  '%00%7Bclosure%7D%2Fin%2FVurX8%3A16%241'
          2        INIT_ARRAY                                       ~1      ~0
   17     3        DECLARE_LAMBDA_FUNCTION                                  '%00%7Bclosure%7D%2Fin%2FVurX8%3A17%242'
          4        ADD_ARRAY_ELEMENT                                ~1      ~2
          5        SEND_ARRAY                                               ~1
          6        CHECK_UNDEF_ARGS                                         
          7        DO_FCALL                                      0          
   19     8      > RETURN                                                   1

Function lib_function:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/VurX8
function name:  lib_function
number of ops:  7
compiled vars:  !0 = $a1, !1 = $a2
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   RECV                                             !0      
          1        RECV                                             !1      
    4     2        INIT_FCALL                                               'var_dump'
          3        SEND_VAR                                                 !0
          4        SEND_VAR                                                 !1
          5        DO_ICALL                                                 
    5     6      > RETURN                                                   null

End of function lib_function

Function i_evaluate_my_arguments:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/VurX8
function name:  i_evaluate_my_arguments
number of ops:  12
compiled vars:  !0 = $evaluated_args
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    8     0  E >   INIT_FCALL                                               'array_map'
          1        DECLARE_LAMBDA_FUNCTION                                  '%00%7Bclosure%7D%2Fin%2FVurX8%3A8%240'
          2        SEND_VAL                                                 ~1
          3        FUNC_GET_ARGS                                    ~2      
          4        SEND_VAL                                                 ~2
          5        DO_ICALL                                         $3      
          6        ASSIGN                                                   !0, $3
   10     7        INIT_FCALL                                               'lib_function'
          8        SEND_ARRAY                                               !0
          9        CHECK_UNDEF_ARGS                                         
         10        DO_FCALL                                      0          
   11    11      > RETURN                                                   null

End of function i_evaluate_my_arguments

Function %00%7Bclosure%7D%2Fin%2FVurX8%3A8%240:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/VurX8
function name:  {closure}
number of ops:  5
compiled vars:  !0 = $a
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    8     0  E >   RECV                                             !0      
          1        INIT_DYNAMIC_CALL                                        !0
          2        DO_FCALL                                      0  $1      
          3      > RETURN                                                   $1
          4*     > RETURN                                                   null

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

Function %00%7Bclosure%7D%2Fin%2FVurX8%3A16%241:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/VurX8
function name:  {closure}
number of ops:  2
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   16     0  E > > RETURN                                                   'foo'
          1*     > RETURN                                                   null

End of function %00%7Bclosure%7D%2Fin%2FVurX8%3A16%241

Function %00%7Bclosure%7D%2Fin%2FVurX8%3A17%242:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/VurX8
function name:  {closure}
number of ops:  2
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   17     0  E > > RETURN                                                   'baz'
          1*     > RETURN                                                   null

End of function %00%7Bclosure%7D%2Fin%2FVurX8%3A17%242

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
156.06 ms | 1403 KiB | 19 Q