3v4l.org

run code in 300+ PHP versions simultaneously
<?php class jefe { function __call($method, $arguments) { $this->$method($arguments); return $this; } } class emp extends jefe { protected function prueba() { echo 'asdf'; } protected function prueba2() { echo '1234'; } } (new emp)->prueba();
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/Df9j5
function name:  (null)
number of ops:  5
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   24     0  E >   NEW                                              $0      'emp'
          1        DO_FCALL                                      0          
          2        INIT_METHOD_CALL                                         $0, 'prueba'
          3        DO_FCALL                                      0          
          4      > RETURN                                                   1

Class jefe:
Function __call:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/Df9j5
function name:  __call
number of ops:  8
compiled vars:  !0 = $method, !1 = $arguments
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    5     0  E >   RECV                                             !0      
          1        RECV                                             !1      
    6     2        INIT_METHOD_CALL                                         !0
          3        SEND_VAR_EX                                              !1
          4        DO_FCALL                                      0          
    7     5        FETCH_THIS                                       ~3      
          6      > RETURN                                                   ~3
    8     7*     > RETURN                                                   null

End of function __call

End of class jefe.

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

End of function prueba

Function prueba2:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/Df9j5
function name:  prueba2
number of ops:  2
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   18     0  E >   ECHO                                                     '1234'
   19     1      > RETURN                                                   null

End of function prueba2

Function __call:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/Df9j5
function name:  __call
number of ops:  8
compiled vars:  !0 = $method, !1 = $arguments
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    5     0  E >   RECV                                             !0      
          1        RECV                                             !1      
    6     2        INIT_METHOD_CALL                                         !0
          3        SEND_VAR_EX                                              !1
          4        DO_FCALL                                      0          
    7     5        FETCH_THIS                                       ~3      
          6      > RETURN                                                   ~3
    8     7*     > RETURN                                                   null

End of function __call

End of class emp.

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
151.03 ms | 1395 KiB | 13 Q