3v4l.org

run code in 300+ PHP versions simultaneously
<?php function x() { global $hello; $hello = true; function y() { global $hello; var_dump($hello); } y(); } x();
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/YNhl6
function name:  (null)
number of ops:  3
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   17     0  E >   INIT_FCALL                                               'x'
          1        DO_FCALL                                      0          
          2      > RETURN                                                   1

Function x:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/YNhl6
function name:  x
number of ops:  6
compiled vars:  !0 = $hello
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    4     0  E >   BIND_GLOBAL                                              !0, 'hello'
    6     1        ASSIGN                                                   !0, <true>
    8     2        DECLARE_FUNCTION                                         'y'
   14     3        INIT_FCALL_BY_NAME                                       'y'
          4        DO_FCALL                                      0          
   15     5      > RETURN                                                   null

End of function x

Function %00y%2Fin%2FYNhl6%3A8%240:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/YNhl6
function name:  y
number of ops:  5
compiled vars:  !0 = $hello
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    9     0  E >   BIND_GLOBAL                                              !0, 'hello'
   11     1        INIT_FCALL                                               'var_dump'
          2        SEND_VAR                                                 !0
          3        DO_ICALL                                                 
   12     4      > RETURN                                                   null

End of function %00y%2Fin%2FYNhl6%3A8%240

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
166.74 ms | 944 KiB | 17 Q