3v4l.org

run code in 300+ PHP versions simultaneously
<?php function f(Osoba $o){ $o->programuj(); } class Osoba { protected $pesel; public function __construct($pesel){ $this-> pesel = $pesel; } public function getPesel(){ return $this -> pesel; } } class Programista extends Osoba{ public function programuj(){ } } $p = new Programista(76021011673); // fatal error f($p);
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/GUum8
function name:  (null)
number of ops:  8
compiled vars:  !0 = $p
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   26     0  E >   NEW                                              $1      'Programista'
          1        SEND_VAL_EX                                              76021011673
          2        DO_FCALL                                      0          
          3        ASSIGN                                                   !0, $1
   28     4        INIT_FCALL                                               'f'
          5        SEND_VAR                                                 !0
          6        DO_FCALL                                      0          
          7      > RETURN                                                   1

Function f:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/GUum8
function name:  f
number of ops:  4
compiled vars:  !0 = $o
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   RECV                                             !0      
    4     1        INIT_METHOD_CALL                                         !0, 'programuj'
          2        DO_FCALL                                      0          
    5     3      > RETURN                                                   null

End of function f

Class Osoba:
Function __construct:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/GUum8
function name:  __construct
number of ops:  4
compiled vars:  !0 = $pesel
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   11     0  E >   RECV                                             !0      
   12     1        ASSIGN_OBJ                                               'pesel'
          2        OP_DATA                                                  !0
   13     3      > RETURN                                                   null

End of function __construct

Function getpesel:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/GUum8
function name:  getPesel
number of ops:  3
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   16     0  E >   FETCH_OBJ_R                                      ~0      'pesel'
          1      > RETURN                                                   ~0
   17     2*     > RETURN                                                   null

End of function getpesel

End of class Osoba.

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

End of function programuj

Function __construct:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/GUum8
function name:  __construct
number of ops:  4
compiled vars:  !0 = $pesel
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   11     0  E >   RECV                                             !0      
   12     1        ASSIGN_OBJ                                               'pesel'
          2        OP_DATA                                                  !0
   13     3      > RETURN                                                   null

End of function __construct

Function getpesel:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/GUum8
function name:  getPesel
number of ops:  3
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   16     0  E >   FETCH_OBJ_R                                      ~0      'pesel'
          1      > RETURN                                                   ~0
   17     2*     > RETURN                                                   null

End of function getpesel

End of class Programista.

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
150.11 ms | 1394 KiB | 14 Q