3v4l.org

run code in 500+ PHP versions simultaneously
<?php ob_start(function() { $foo = new Foo; set_error_handler(function() use ($foo) {}); }); class Foo { public function __destruct() { var_dump($GLOBALS); } }
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/X3oEK
function name:  (null)
number of ops:  5
compiled vars:  none
line      #* E I O op                               fetch          ext  return  operands
-----------------------------------------------------------------------------------------
    3     0  E >   INIT_FCALL                                                   'ob_start'
          1        DECLARE_LAMBDA_FUNCTION                              ~0      [0]
    6     2        SEND_VAL                                                     ~0
    3     3        DO_ICALL                                                     
   12     4      > RETURN                                                       1


Dynamic Functions:
Dynamic Function 0
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/X3oEK
function name:  {closure:/in/X3oEK:3}
number of ops:  9
compiled vars:  !0 = $foo
line      #* E I O op                               fetch          ext  return  operands
-----------------------------------------------------------------------------------------
    4     0  E >   NEW                                                  $1      'Foo'
          1        DO_FCALL                                          0          
          2        ASSIGN                                                       !0, $1
    5     3        INIT_FCALL                                                   'set_error_handler'
          4        DECLARE_LAMBDA_FUNCTION                              ~4      [0]
          5        BIND_LEXICAL                                                 ~4, !0
          6        SEND_VAL                                                     ~4
          7        DO_ICALL                                                     
    6     8      > RETURN                                                       null


Dynamic Functions:
Dynamic Function 0
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/X3oEK
function name:  {closure:{closure:/in/X3oEK:3}:5}
number of ops:  2
compiled vars:  !0 = $foo
line      #* E I O op                               fetch          ext  return  operands
-----------------------------------------------------------------------------------------
    5     0  E >   BIND_STATIC                                                  !0
          1      > RETURN                                                       null

End of Dynamic Function 0

End of Dynamic Function 0

Class Foo:
Function __destruct:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/X3oEK
function name:  __destruct
number of ops:  5
compiled vars:  none
line      #* E I O op                               fetch          ext  return  operands
-----------------------------------------------------------------------------------------
   10     0  E >   INIT_FCALL                                                   'var_dump'
          1        FETCH_GLOBALS                                        ~0      
          2        SEND_VAL                                                     ~0
          3        DO_ICALL                                                     
   11     4      > RETURN                                                       null

End of function __destruct

End of class Foo.

Generated using Vulcan Logic Dumper, using php 8.5.0


preferences:
164.99 ms | 2640 KiB | 16 Q