3v4l.org

run code in 300+ PHP versions simultaneously
<?php spl_autoload_register(function ($class_name) { echo "Need to include `{$class_name}` \n"; }); try { try { throw new \RuntimeException('Error message'); } finally { try { echo 'Start finally block' . PHP_EOL; throw new RuntimeException('asd'); echo 'End finally block' . PHP_EOL; } catch (Throwable $ex) { echo 'Finally catch ' . $ex->getMessage() . PHP_EOL; throw $ex; } } } catch (\Throwable $e) { echo $e->getMessage() . PHP_EOL; echo $e . PHP_EOL; }
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 108) Position 1 = -2
Found catch point at position: 17
Branch analysis from position: 17
2 jumps found. (Code = 107) Position 1 = 18, Position 2 = -2
Branch analysis from position: 18
1 jumps found. (Code = 108) Position 1 = -2
Found catch point at position: 26
Branch analysis from position: 26
2 jumps found. (Code = 107) Position 1 = 27, Position 2 = -2
Branch analysis from position: 27
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/SbEiv
function name:  (null)
number of ops:  34
compiled vars:  !0 = $ex, !1 = $e
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    2     0  E >   INIT_FCALL                                               'spl_autoload_register'
          1        DECLARE_LAMBDA_FUNCTION                                  '%00%7Bclosure%7D%2Fin%2FSbEiv%3A2%240'
    4     2        SEND_VAL                                                 ~2
          3        DO_ICALL                                                 
    8     4        NEW                                              $5      'RuntimeException'
          5        SEND_VAL_EX                                              'Error+message'
          6        DO_FCALL                                      0          
          7      > THROW                                         0          $5
    9     8*       FAST_CALL                                                ->10
          9*       JMP                                                      ->25
   12    10*       ECHO                                                     'Start+finally+block%0A'
   14    11*       NEW                                              $7      'RuntimeException'
         12*       SEND_VAL_EX                                              'asd'
         13*       DO_FCALL                                      0          
         14*       THROW                                         0          $7
   16    15*       ECHO                                                     'End+finally+block%0A'
         16*       JMP                                                      ->24
   17    17  E > > CATCH                                       last         'Throwable'
   18    18    >   INIT_METHOD_CALL                                         !0, 'getMessage'
         19        DO_FCALL                                      0  $9      
         20        CONCAT                                           ~10     'Finally+catch+', $9
         21        CONCAT                                           ~11     ~10, '%0A'
         22        ECHO                                                     ~11
   19    23      > THROW                                         0          !0
         24*       FAST_RET                                                 
         25*       JMP                                                      ->33
   23    26  E > > CATCH                                       last         'Throwable'
   24    27    >   INIT_METHOD_CALL                                         !1, 'getMessage'
         28        DO_FCALL                                      0  $12     
         29        CONCAT                                           ~13     $12, '%0A'
         30        ECHO                                                     ~13
   25    31        CONCAT                                           ~14     !1, '%0A'
         32        ECHO                                                     ~14
   26    33      > RETURN                                                   1

Function %00%7Bclosure%7D%2Fin%2FSbEiv%3A2%240:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/SbEiv
function name:  {closure}
number of ops:  6
compiled vars:  !0 = $class_name
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    2     0  E >   RECV                                             !0      
    3     1        ROPE_INIT                                     3  ~2      'Need+to+include+%60'
          2        ROPE_ADD                                      1  ~2      ~2, !0
          3        ROPE_END                                      2  ~1      ~2, '%60+%0A'
          4        ECHO                                                     ~1
    4     5      > RETURN                                                   null

End of function %00%7Bclosure%7D%2Fin%2FSbEiv%3A2%240

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
165.99 ms | 1400 KiB | 15 Q