3v4l.org

run code in 300+ PHP versions simultaneously
<?php class Some { public function __construct() { echo get_class($this); } } class Any extends Some { public function call_construct() { parent::__construct(); } } $some = new Some; $any = new Any; $any->call_construct();
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/mLeU8
function name:  (null)
number of ops:  9
compiled vars:  !0 = $some, !1 = $any
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   22     0  E >   NEW                                              $2      'Some'
          1        DO_FCALL                                      0          
          2        ASSIGN                                                   !0, $2
   24     3        NEW                                              $5      'Any'
          4        DO_FCALL                                      0          
          5        ASSIGN                                                   !1, $5
   26     6        INIT_METHOD_CALL                                         !1, 'call_construct'
          7        DO_FCALL                                      0          
          8      > RETURN                                                   1

Class Some:
Function __construct:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/mLeU8
function name:  __construct
number of ops:  4
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    6     0  E >   FETCH_THIS                                       ~0      
          1        GET_CLASS                                        ~1      ~0
          2        ECHO                                                     ~1
    7     3      > RETURN                                                   null

End of function __construct

End of class Some.

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

End of function call_construct

Function __construct:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/mLeU8
function name:  __construct
number of ops:  4
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    6     0  E >   FETCH_THIS                                       ~0      
          1        GET_CLASS                                        ~1      ~0
          2        ECHO                                                     ~1
    7     3      > RETURN                                                   null

End of function __construct

End of class Any.

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
156.31 ms | 1395 KiB | 13 Q