3v4l.org

run code in 300+ PHP versions simultaneously
<?php $product = array('material', 'britelki', 'chaschka', 'kostochki', 'vkladish', 'zastejka'); //function create_from_variable($arr){ foreach($product as $key){ $var = "show_the_product_".$key; echo $var; $$var = function(){ echo '123'; }; } //} //create_from_variable($product); $show_the_product_material(); $thing = 'some_function'; $$thing = function() { echo 'hi'; }; $some_function();
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 77) Position 1 = 2, Position 2 = 10
Branch analysis from position: 2
2 jumps found. (Code = 78) Position 1 = 3, Position 2 = 10
Branch analysis from position: 3
1 jumps found. (Code = 42) Position 1 = 2
Branch analysis from position: 2
Branch analysis from position: 10
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 10
filename:       /in/U4NMd
function name:  (null)
number of ops:  20
compiled vars:  !0 = $product, !1 = $key, !2 = $var, !3 = $show_the_product_material, !4 = $thing, !5 = $some_function
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    2     0  E >   ASSIGN                                                   !0, <array>
    6     1      > FE_RESET_R                                       $7      !0, ->10
          2    > > FE_FETCH_R                                               $7, !1, ->10
    9     3    >   CONCAT                                           ~8      'show_the_product_', !1
          4        ASSIGN                                                   !2, ~8
   10     5        ECHO                                                     !2
   12     6        DECLARE_LAMBDA_FUNCTION                                  '%00%7Bclosure%7D%2Fin%2FU4NMd%3A12%240'
          7        FETCH_W                      local               $10     !2
          8        ASSIGN                                                   $10, ~11
    6     9      > JMP                                                      ->2
         10    >   FE_FREE                                                  $7
   25    11        INIT_DYNAMIC_CALL                                        !3
         12        DO_FCALL                                      0          
   28    13        ASSIGN                                                   !4, 'some_function'
   29    14        DECLARE_LAMBDA_FUNCTION                                  '%00%7Bclosure%7D%2Fin%2FU4NMd%3A29%241'
         15        FETCH_W                      local               $15     !4
         16        ASSIGN                                                   $15, ~16
   32    17        INIT_DYNAMIC_CALL                                        !5
         18        DO_FCALL                                      0          
         19      > RETURN                                                   1

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

End of function %00%7Bclosure%7D%2Fin%2FU4NMd%3A12%240

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

End of function %00%7Bclosure%7D%2Fin%2FU4NMd%3A29%241

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
155.35 ms | 1395 KiB | 13 Q