3v4l.org

run code in 300+ PHP versions simultaneously
<?php class BadRequestException extends Exception { protected $code = 404; public function __construct($message = '', $code = 0, Exception $previous = NULL) { parent::__construct($message, $code < 200 || $code > 504 ? $this->code : $code, $previous); } } $e = new BadRequestException("test", 418); var_dump($e);
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/m9Sah
function name:  (null)
number of ops:  9
compiled vars:  !0 = $e
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   14     0  E >   NEW                                              $1      'BadRequestException'
          1        SEND_VAL_EX                                              'test'
          2        SEND_VAL_EX                                              418
          3        DO_FCALL                                      0          
          4        ASSIGN                                                   !0, $1
   15     5        INIT_FCALL                                               'var_dump'
          6        SEND_VAR                                                 !0
          7        DO_ICALL                                                 
          8      > RETURN                                                   1

Class BadRequestException:
Function __construct:
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 47) Position 1 = 7, Position 2 = 9
Branch analysis from position: 7
2 jumps found. (Code = 43) Position 1 = 10, Position 2 = 13
Branch analysis from position: 10
1 jumps found. (Code = 42) Position 1 = 14
Branch analysis from position: 14
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 13
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 9
filename:       /in/m9Sah
function name:  __construct
number of ops:  18
compiled vars:  !0 = $message, !1 = $code, !2 = $previous
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    7     0  E >   RECV_INIT                                        !0      ''
          1        RECV_INIT                                        !1      0
          2        RECV_INIT                                        !2      null
    9     3        INIT_STATIC_METHOD_CALL                                  
          4        SEND_VAR_EX                                              !0
          5        IS_SMALLER                                       ~3      !1, 200
          6      > JMPNZ_EX                                         ~3      ~3, ->9
          7    >   IS_SMALLER                                       ~4      504, !1
          8        BOOL                                             ~3      ~4
          9    > > JMPZ                                                     ~3, ->13
         10    >   FETCH_OBJ_R                                      ~5      'code'
         11        QM_ASSIGN                                        ~6      ~5
         12      > JMP                                                      ->14
         13    >   QM_ASSIGN                                        ~6      !1
         14    >   SEND_VAL_EX                                              ~6
         15        SEND_VAR_EX                                              !2
         16        DO_FCALL                                      0          
   10    17      > RETURN                                                   null

End of function __construct

End of class BadRequestException.

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
171.85 ms | 1396 KiB | 15 Q