3v4l.org

run code in 300+ PHP versions simultaneously
<?php class P { public function __construct($arg) { echo "Parent constructor"; } } class C extends P { public function __construct(/* no arg */) { parent::__construct(3); } } class GC extends C { public function __construct($arg1, $arg2) { parent::__construct(); } } class GGC extends GC { public function __construct(/* no args */) { parent::__construct(1, 2); } } new GC(1, 2);
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/1G8n88
function name:  (null)
number of ops:  6
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   24     0  E >   NEW                                              $0      'GC'
          1        SEND_VAL_EX                                              1
          2        SEND_VAL_EX                                              2
          3        DO_FCALL                                      0          
          4        FREE                                                     $0
          5      > RETURN                                                   1

Class P:
Function __construct:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/1G8n88
function name:  __construct
number of ops:  3
compiled vars:  !0 = $arg
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    4     0  E >   RECV                                             !0      
    5     1        ECHO                                                     'Parent+constructor'
    6     2      > RETURN                                                   null

End of function __construct

End of class P.

Class C:
Function __construct:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/1G8n88
function name:  __construct
number of ops:  4
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   10     0  E >   INIT_STATIC_METHOD_CALL                                  
          1        SEND_VAL_EX                                              3
          2        DO_FCALL                                      0          
   11     3      > RETURN                                                   null

End of function __construct

End of class C.

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

End of function __construct

End of class GC.

Class GGC:
Function __construct:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/1G8n88
function name:  __construct
number of ops:  5
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   20     0  E >   INIT_STATIC_METHOD_CALL                                  
          1        SEND_VAL_EX                                              1
          2        SEND_VAL_EX                                              2
          3        DO_FCALL                                      0          
   21     4      > RETURN                                                   null

End of function __construct

End of class GGC.

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
179.46 ms | 942 KiB | 14 Q