3v4l.org

run code in 300+ PHP versions simultaneously
<?php trait A { function calc1($v) { echo 'ttttttttttttt'; return $v+1; } } class MyClass { use A; function calc($v) { echo '123'; $this->calc1(); //parent::calc($v); } } $x=new MyClass(); $x->calc(123);
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/TVqe4
function name:  (null)
number of ops:  8
compiled vars:  !0 = $x
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    9     0  E >   DECLARE_CLASS                                            'myclass'
   19     1        NEW                                              $1      'MyClass'
          2        DO_FCALL                                      0          
          3        ASSIGN                                                   !0, $1
   20     4        INIT_METHOD_CALL                                         !0, 'calc'
          5        SEND_VAL_EX                                              123
          6        DO_FCALL                                      0          
          7      > RETURN                                                   1

Class A:
Function calc1:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/TVqe4
function name:  calc1
number of ops:  5
compiled vars:  !0 = $v
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   RECV                                             !0      
    4     1        ECHO                                                     'ttttttttttttt'
    5     2        ADD                                              ~1      !0, 1
          3      > RETURN                                                   ~1
    6     4*     > RETURN                                                   null

End of function calc1

End of class A.

Class MyClass:
Function calc:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/TVqe4
function name:  calc
number of ops:  5
compiled vars:  !0 = $v
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   12     0  E >   RECV                                             !0      
   13     1        ECHO                                                     '123'
   14     2        INIT_METHOD_CALL                                         'calc1'
          3        DO_FCALL                                      0          
   16     4      > RETURN                                                   null

End of function calc

End of class MyClass.

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
182.82 ms | 1394 KiB | 13 Q