3v4l.org

run code in 300+ PHP versions simultaneously
<?php interface Bar { public function augment(); } abstract class Baz implements Bar { public function __construct($data) { $this->data = $data; $this->augment(); } } class Foo extends Baz { public function augment() { $this->data = strtoupper($this->data); } } $foo = new Foo('imlower');
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/jsEYk
function name:  (null)
number of ops:  7
compiled vars:  !0 = $foo
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    7     0  E >   DECLARE_CLASS                                            'baz'
   16     1        DECLARE_CLASS                                            'foo', 'baz'
   24     2        NEW                                              $1      'Foo'
          3        SEND_VAL_EX                                              'imlower'
          4        DO_FCALL                                      0          
          5        ASSIGN                                                   !0, $1
          6      > RETURN                                                   1

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

End of function augment

End of class Bar.

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

End of function __construct

End of class Baz.

Class Foo:
Function augment:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/jsEYk
function name:  augment
number of ops:  7
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   20     0  E >   INIT_FCALL                                               'strtoupper'
          1        FETCH_OBJ_R                                      ~1      'data'
          2        SEND_VAL                                                 ~1
          3        DO_ICALL                                         $2      
          4        ASSIGN_OBJ                                               'data'
          5        OP_DATA                                                  $2
   21     6      > RETURN                                                   null

End of function augment

End of class Foo.

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
158.14 ms | 1396 KiB | 15 Q