3v4l.org

run code in 300+ PHP versions simultaneously
<?php namespace foo { class Xyz {} function abc () {} } namespace bar { use foo\Xyz; use foo\abc; function abc() { echo 'asdf'; } var_dump(new Xyz()); // instantiates \foo\Xyz var_dump(abc()); var_dump(\foo\abc()); // it has to be invoked using the fully qualified name } ?>
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/p8Xpg
function name:  (null)
number of ops:  16
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   23     0  E >   INIT_NS_FCALL_BY_NAME                                    'bar%5Cvar_dump'
          1        NEW                                              $0      'foo%5CXyz'
          2        DO_FCALL                                      0          
          3        SEND_VAR_NO_REF_EX                                       $0
          4        DO_FCALL                                      0          
   25     5        INIT_NS_FCALL_BY_NAME                                    'bar%5Cvar_dump'
          6        INIT_NS_FCALL_BY_NAME                                    'bar%5Cabc'
          7        DO_FCALL                                      0  $3      
          8        SEND_VAR_NO_REF_EX                                       $3
          9        DO_FCALL                                      0          
   26    10        INIT_NS_FCALL_BY_NAME                                    'bar%5Cvar_dump'
         11        INIT_FCALL                                               'foo%5Cabc'
         12        DO_FCALL                                      0  $5      
         13        SEND_VAR_NO_REF_EX                                       $5
         14        DO_FCALL                                      0          
   39    15      > RETURN                                                   1

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

End of function foo%5Cabc

Function bar%5Cabc:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/p8Xpg
function name:  bar\abc
number of ops:  2
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   18     0  E >   ECHO                                                     'asdf'
   19     1      > RETURN                                                   null

End of function bar%5Cabc

Class foo\Xyz: [no user functions]

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
168.37 ms | 1397 KiB | 17 Q