3v4l.org

run code in 300+ PHP versions simultaneously
<?php trait Foo { use Foo { ff as abc; } private function a() { return 'sf';} public function ff() { return '2424';}} class Bar {use Foo; } class An extends Bar { use Foo; public $var; } var_dump((new An())->abc());
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/aej1E
function name:  (null)
number of ops:  11
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    2     0  E >   DECLARE_CLASS                                            'foo'
    4     1        DECLARE_CLASS                                            'bar'
    6     2        DECLARE_CLASS                                            'an', 'bar'
    8     3        INIT_FCALL                                               'var_dump'
          4        NEW                                              $0      'An'
          5        DO_FCALL                                      0          
          6        INIT_METHOD_CALL                                         $0, 'abc'
          7        DO_FCALL                                      0  $2      
          8        SEND_VAR                                                 $2
          9        DO_ICALL                                                 
         10      > RETURN                                                   1

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

End of function a

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

End of function ff

End of class Foo.

Class Bar: [no user functions]
Class An: [no user functions]

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
152.12 ms | 1395 KiB | 15 Q