3v4l.org

run code in 300+ PHP versions simultaneously
<?php $s_one = '1'; $i_two = '2'; $a_three = array(3 => '3'); //$add = function(...$data){ // // foreach($data as $key => $value) { // yield $key => $value; // } //} $string = function() use ($s_one) { return 'dupa' . $s_one; }; echo $string(); //$string('dupa'); //var_dump($add($s_one, $i_two, $a_three));
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/DaCeu
function name:  (null)
number of ops:  10
compiled vars:  !0 = $s_one, !1 = $i_two, !2 = $a_three, !3 = $string
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   ASSIGN                                                   !0, '1'
    4     1        ASSIGN                                                   !1, '2'
    5     2        ASSIGN                                                   !2, <array>
   14     3        DECLARE_LAMBDA_FUNCTION                                  '%00%7Bclosure%7D%2Fin%2FDaCeu%3A14%240'
          4        BIND_LEXICAL                                             ~7, !0
          5        ASSIGN                                                   !3, ~7
   18     6        INIT_DYNAMIC_CALL                                        !3
          7        DO_FCALL                                      0  $9      
          8        ECHO                                                     $9
   20     9      > RETURN                                                   1

Function %00%7Bclosure%7D%2Fin%2FDaCeu%3A14%240:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/DaCeu
function name:  {closure}
number of ops:  4
compiled vars:  !0 = $s_one
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   14     0  E >   BIND_STATIC                                              !0
   15     1        CONCAT                                           ~1      'dupa', !0
          2      > RETURN                                                   ~1
   16     3*     > RETURN                                                   null

End of function %00%7Bclosure%7D%2Fin%2FDaCeu%3A14%240

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
152.88 ms | 1385 KiB | 13 Q