3v4l.org

run code in 300+ PHP versions simultaneously
<?php class Base { public function __construct(string $bar) { echo 'foo'; } } class MD extends Base { public function __construct($bar) { parent::__construct($bar); echo $bar; } } $md = new MD('bar');
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/dUDYE
function name:  (null)
number of ops:  5
compiled vars:  !0 = $md
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   20     0  E >   NEW                                              $1      'MD'
          1        SEND_VAL_EX                                              'bar'
          2        DO_FCALL                                      0          
          3        ASSIGN                                                   !0, $1
          4      > RETURN                                                   1

Class Base:
Function __construct:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/dUDYE
function name:  __construct
number of ops:  3
compiled vars:  !0 = $bar
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    5     0  E >   RECV                                             !0      
    7     1        ECHO                                                     'foo'
    8     2      > RETURN                                                   null

End of function __construct

End of class Base.

Class MD:
Function __construct:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/dUDYE
function name:  __construct
number of ops:  6
compiled vars:  !0 = $bar
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   13     0  E >   RECV                                             !0      
   15     1        INIT_STATIC_METHOD_CALL                                  
          2        SEND_VAR_EX                                              !0
          3        DO_FCALL                                      0          
   16     4        ECHO                                                     !0
   17     5      > RETURN                                                   null

End of function __construct

End of class MD.

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
138.68 ms | 1433 KiB | 13 Q