3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php namespace MyProject { const CONNECT_OK = 1; class Connection { static public function start() { echo 'started'; } } function connect() { /* ... */ } } namespace { // global code echo phpversion(); session_start(); $a = MyProject\connect(); echo MyProject\Connection::start(); }
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/nWO8W
function name:  (null)
number of ops:  15
compiled vars:  !0 = $a
line     #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   4     0  E >   DECLARE_CONST                                            'MyProject%5CCONNECT_OK', 1
   5     1        NOP                                                      
   6     2        NOP                                                      
  10     3        INIT_FCALL                                               'phpversion'
         4        DO_ICALL                                         $2      
         5        ECHO                                                     $2
  11     6        INIT_FCALL                                               'session_start'
         7        DO_ICALL                                                 
  12     8        INIT_FCALL                                               'myproject%5Cconnect'
         9        DO_FCALL                                      0  $4      
        10        ASSIGN                                                   !0, $4
  13    11        INIT_STATIC_METHOD_CALL                                  'MyProject%5CConnection', 'start'
        12        DO_FCALL                                      0  $6      
        13        ECHO                                                     $6
  14    14      > RETURN                                                   1

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

End of function myproject%5Cconnect

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

End of function start

End of class MyProject\Connection.

Generated using Vulcan Logic Dumper, using php 7.3.0