3v4l.org

run code in 300+ PHP versions simultaneously
<?php function throwStupidException() { echo 'Just about to throw the exception.' . "\n"; try { throw new Exception('This is stupid'); } finally { echo 'Finally!' . "\n"; } } try { echo 'Let\'s do this.' . "\n"; throwStupidException(); } catch (Exception $e) { echo 'Caught stupid exception!' . "\n"; }
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 42) Position 1 = 6
Branch analysis from position: 6
1 jumps found. (Code = 62) Position 1 = -2
Found catch point at position: 4
Branch analysis from position: 4
2 jumps found. (Code = 107) Position 1 = 5, Position 2 = -2
Branch analysis from position: 5
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/Kfi68
function name:  (null)
number of ops:  7
compiled vars:  !0 = $e
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   14     0  E >   ECHO                                                     'Let%27s+do+this.%0A'
   15     1        INIT_FCALL                                               'throwstupidexception'
          2        DO_FCALL                                      0          
          3      > JMP                                                      ->6
   16     4  E > > CATCH                                       last         'Exception'
   17     5    >   ECHO                                                     'Caught+stupid+exception%21%0A'
   18     6    > > RETURN                                                   1

Function throwstupidexception:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 108) Position 1 = -2
filename:       /in/Kfi68
function name:  throwStupidException
number of ops:  10
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    5     0  E >   ECHO                                                     'Just+about+to+throw+the+exception.%0A'
    7     1        NEW                                              $1      'Exception'
          2        SEND_VAL_EX                                              'This+is+stupid'
          3        DO_FCALL                                      0          
          4      > THROW                                         0          $1
    8     5*       FAST_CALL                                                ->7
          6*       JMP                                                      ->9
    9     7*       ECHO                                                     'Finally%21%0A'
          8*       FAST_RET                                                 
   11     9*     > RETURN                                                   null

End of function throwstupidexception

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
126.83 ms | 945 KiB | 15 Q