3v4l.org

run code in 300+ PHP versions simultaneously
<?php function foo() { yield 'pwned!'; } $a = 'foo'; @${a}(); $b[] = $a; $b[0]();
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/DIWpA
function name:  (null)
number of ops:  13
compiled vars:  !0 = $a, !1 = $b
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    8     0  E >   ASSIGN                                                   !0, 'foo'
    9     1        BEGIN_SILENCE                                    ~3      
          2        FETCH_CONSTANT                                   ~4      'a'
          3        FETCH_R                      local               ~5      ~4
          4        INIT_DYNAMIC_CALL                                        ~5
          5        DO_FCALL                                      0          
          6        END_SILENCE                                              ~3
   10     7        ASSIGN_DIM                                               !1
          8        OP_DATA                                                  !0
   11     9        FETCH_DIM_R                                      ~8      !1, 0
         10        INIT_DYNAMIC_CALL                                        ~8
         11        DO_FCALL                                      0          
         12      > RETURN                                                   1

Function foo:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 161) Position 1 = -2
filename:       /in/DIWpA
function name:  foo
number of ops:  3
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   GENERATOR_CREATE                                         
    5     1        YIELD                                                    'pwned%21'
    6     2      > GENERATOR_RETURN                                         

End of function foo

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
172.64 ms | 1393 KiB | 13 Q