3v4l.org

run code in 300+ PHP versions simultaneously
<?php (function($param1){ return function(...$param2) use ($param1){ foreach($param2 as $item) { echo "$param1, $item"; } }; })("Hello")("To You", "To Me");
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/uBvH2
function name:  (null)
number of ops:  9
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   DECLARE_LAMBDA_FUNCTION                                  '%00%7Bclosure%7D%2Fin%2FuBvH2%3A3%240'
   14     1        INIT_DYNAMIC_CALL                                        ~0
          2        SEND_VAL_EX                                              'Hello'
          3        DO_FCALL                                      0  $1      
          4        INIT_DYNAMIC_CALL                                        $1
          5        SEND_VAL_EX                                              'To+You'
          6        SEND_VAL_EX                                              'To+Me'
          7        DO_FCALL                                      0          
          8      > RETURN                                                   1

Function %00%7Bclosure%7D%2Fin%2FuBvH2%3A3%240:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/uBvH2
function name:  {closure}
number of ops:  5
compiled vars:  !0 = $param1
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   RECV                                             !0      
    5     1        DECLARE_LAMBDA_FUNCTION                                  '%00%7Bclosure%7D%2Fin%2FuBvH2%3A5%241'
          2        BIND_LEXICAL                                             ~1, !0
   12     3      > RETURN                                                   ~1
   14     4*     > RETURN                                                   null

End of function %00%7Bclosure%7D%2Fin%2FuBvH2%3A3%240

Function %00%7Bclosure%7D%2Fin%2FuBvH2%3A5%241:
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 77) Position 1 = 3, Position 2 = 9
Branch analysis from position: 3
2 jumps found. (Code = 78) Position 1 = 4, Position 2 = 9
Branch analysis from position: 4
1 jumps found. (Code = 42) Position 1 = 3
Branch analysis from position: 3
Branch analysis from position: 9
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 9
filename:       /in/uBvH2
function name:  {closure}
number of ops:  11
compiled vars:  !0 = $param2, !1 = $param1, !2 = $item
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    5     0  E >   RECV_VARIADIC                                    !0      
          1        BIND_STATIC                                              !1
    7     2      > FE_RESET_R                                       $3      !0, ->9
          3    > > FE_FETCH_R                                               $3, !2, ->9
    9     4    >   ROPE_INIT                                     3  ~5      !1
          5        ROPE_ADD                                      1  ~5      ~5, '%2C+'
          6        ROPE_END                                      2  ~4      ~5, !2
          7        ECHO                                                     ~4
    7     8      > JMP                                                      ->3
          9    >   FE_FREE                                                  $3
   12    10      > RETURN                                                   null

End of function %00%7Bclosure%7D%2Fin%2FuBvH2%3A5%241

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
180.8 ms | 1395 KiB | 13 Q