3v4l.org

run code in 300+ PHP versions simultaneously
<?php class Test { public function __destruct() { echo 'destruct', PHP_EOL; } public function __construct() { echo 'construct', PHP_EOL; } } echo 'start', PHP_EOL; new Test(); throw new Exception(); echo 'stop', PHP_EOL;
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 108) Position 1 = -2
filename:       /in/obEDd
function name:  (null)
number of ops:  11
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   16     0  E >   ECHO                                                     'start'
          1        ECHO                                                     '%0A'
   17     2        NEW                                              $0      'Test'
          3        DO_FCALL                                      0          
          4        FREE                                                     $0
   19     5        NEW                                              $2      'Exception'
          6        DO_FCALL                                      0          
          7      > THROW                                         0          $2
   21     8*       ECHO                                                     'stop'
          9*       ECHO                                                     '%0A'
         10*     > RETURN                                                   1

Class Test:
Function __destruct:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/obEDd
function name:  __destruct
number of ops:  3
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    7     0  E >   ECHO                                                     'destruct'
          1        ECHO                                                     '%0A'
    8     2      > RETURN                                                   null

End of function __destruct

Function __construct:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/obEDd
function name:  __construct
number of ops:  3
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   12     0  E >   ECHO                                                     'construct'
          1        ECHO                                                     '%0A'
   13     2      > RETURN                                                   null

End of function __construct

End of class Test.

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
163.73 ms | 1385 KiB | 13 Q