3v4l.org

run code in 300+ PHP versions simultaneously
<?php class blocks { public function function() { echo 'hello'; } } class otherClass { public $blocks; public function __construct() { $this->blocks = new blocks; } public function test() { $this->blocks->function(); } } $obj = new otherClass; $obj->test();
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/eLCAI
function name:  (null)
number of ops:  6
compiled vars:  !0 = $obj
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   19     0  E >   NEW                                              $1      'otherClass'
          1        DO_FCALL                                      0          
          2        ASSIGN                                                   !0, $1
   20     3        INIT_METHOD_CALL                                         !0, 'test'
          4        DO_FCALL                                      0          
          5      > RETURN                                                   1

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

End of function function

End of class blocks.

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

End of function __construct

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

End of function test

End of class otherClass.

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
155.85 ms | 1395 KiB | 13 Q