3v4l.org

run code in 300+ PHP versions simultaneously
<?php error_reporting(E_ALL); ini_set(display_errors, 'on'); try { //$x = strtotime('blah'); $x = new DateTime('lol'); } catch ( Exception $e ) { echo $e->getMessage(); }
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 42) Position 1 = 17
Branch analysis from position: 17
1 jumps found. (Code = 62) Position 1 = -2
Found catch point at position: 13
Branch analysis from position: 13
2 jumps found. (Code = 107) Position 1 = 14, Position 2 = -2
Branch analysis from position: 14
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/RggtP
function name:  (null)
number of ops:  18
compiled vars:  !0 = $x, !1 = $e
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    2     0  E >   INIT_FCALL                                               'error_reporting'
          1        SEND_VAL                                                 32767
          2        DO_ICALL                                                 
    3     3        INIT_FCALL                                               'ini_set'
          4        FETCH_CONSTANT                                   ~3      'display_errors'
          5        SEND_VAL                                                 ~3
          6        SEND_VAL                                                 'on'
          7        DO_ICALL                                                 
    7     8        NEW                                              $5      'DateTime'
          9        SEND_VAL_EX                                              'lol'
         10        DO_FCALL                                      0          
         11        ASSIGN                                                   !0, $5
         12      > JMP                                                      ->17
    8    13  E > > CATCH                                       last         'Exception'
    9    14    >   INIT_METHOD_CALL                                         !1, 'getMessage'
         15        DO_FCALL                                      0  $8      
         16        ECHO                                                     $8
   10    17    > > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
154.66 ms | 1399 KiB | 17 Q