3v4l.org

run code in 300+ PHP versions simultaneously
<?php class FooClass { public $string = 'this is some string'; } function getObject() { return new FooClass; } echo getObject()->string;
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/dkItH
function name:  (null)
number of ops:  5
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   13     0  E >   INIT_FCALL                                               'getobject'
          1        DO_FCALL                                      0  $0      
          2        FETCH_OBJ_R                                      ~1      $0, 'string'
          3        ECHO                                                     ~1
          4      > RETURN                                                   1

Function getobject:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/dkItH
function name:  getObject
number of ops:  4
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   10     0  E >   NEW                                              $0      'FooClass'
          1        DO_FCALL                                      0          
          2      > RETURN                                                   $0
   11     3*     > RETURN                                                   null

End of function getobject

Class FooClass: [no user functions]

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
159.4 ms | 1397 KiB | 14 Q