3v4l.org

run code in 300+ PHP versions simultaneously
<?php $product = array('material', 'britelki', 'chaschka', 'kostochki', 'vkladish', 'zastejka'); foreach($product as $key){ $var = "show_the_product_".$key; $$var = function(){ ${"gc_".$key} = 'gc_'.$key.''; if ((isset(${"gc_".$key})) && (${"gc_".$key} != '')) { echo "<p class=\"goods-material\">$gc_".$key."</p>"; } }; } $show_the_product_material();
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 77) Position 1 = 2, Position 2 = 9
Branch analysis from position: 2
2 jumps found. (Code = 78) Position 1 = 3, Position 2 = 9
Branch analysis from position: 3
1 jumps found. (Code = 42) Position 1 = 2
Branch analysis from position: 2
Branch analysis from position: 9
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 9
filename:       /in/vbclC
function name:  (null)
number of ops:  13
compiled vars:  !0 = $product, !1 = $key, !2 = $var, !3 = $show_the_product_material
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    2     0  E >   ASSIGN                                                   !0, <array>
    4     1      > FE_RESET_R                                       $5      !0, ->9
          2    > > FE_FETCH_R                                               $5, !1, ->9
    6     3    >   CONCAT                                           ~6      'show_the_product_', !1
          4        ASSIGN                                                   !2, ~6
    8     5        DECLARE_LAMBDA_FUNCTION                                  '%00%7Bclosure%7D%2Fin%2FvbclC%3A8%240'
          6        FETCH_W                      local               $8      !2
          7        ASSIGN                                                   $8, ~9
    4     8      > JMP                                                      ->2
          9    >   FE_FREE                                                  $5
   20    10        INIT_DYNAMIC_CALL                                        !3
         11        DO_FCALL                                      0          
         12      > RETURN                                                   1

Function %00%7Bclosure%7D%2Fin%2FvbclC%3A8%240:
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 46) Position 1 = 8, Position 2 = 12
Branch analysis from position: 8
2 jumps found. (Code = 43) Position 1 = 13, Position 2 = 18
Branch analysis from position: 13
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 18
Branch analysis from position: 12
filename:       /in/vbclC
function name:  {closure}
number of ops:  19
compiled vars:  !0 = $key, !1 = $gc_
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   10     0  E >   CONCAT                                           ~2      'gc_', !0
          1        CONCAT                                           ~4      'gc_', !0
          2        CONCAT                                           ~5      ~4, ''
          3        FETCH_W                      local               $3      ~2
          4        ASSIGN                                                   $3, ~5
   11     5        CONCAT                                           ~7      'gc_', !0
          6        ISSET_ISEMPTY_VAR                             4  ~8      ~7
          7      > JMPZ_EX                                          ~8      ~8, ->12
          8    >   CONCAT                                           ~9      'gc_', !0
          9        FETCH_R                      local               ~10     ~9
         10        IS_NOT_EQUAL                                     ~11     ~10, ''
         11        BOOL                                             ~8      ~11
         12    > > JMPZ                                                     ~8, ->18
   12    13    >   NOP                                                      
         14        FAST_CONCAT                                      ~12     '%3Cp+class%3D%22goods-material%22%3E', !1
         15        CONCAT                                           ~13     ~12, !0
         16        CONCAT                                           ~14     ~13, '%3C%2Fp%3E'
         17        ECHO                                                     ~14
   16    18    > > RETURN                                                   null

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

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
150.05 ms | 1399 KiB | 13 Q