3v4l.org

run code in 300+ PHP versions simultaneously
<?php error_reporting(E_ALL); function f($x) { return $x; } $x = 'variable'; const x = 'const'; echo "${f(x)}";
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/jHHLP
function name:  (null)
number of ops:  13
compiled vars:  !0 = $x
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   INIT_FCALL                                               'error_reporting'
          1        SEND_VAL                                                 32767
          2        DO_ICALL                                                 
    9     3        ASSIGN                                                   !0, 'variable'
   10     4        DECLARE_CONST                                            'x', 'const'
   11     5        INIT_FCALL                                               'f'
          6        FETCH_CONSTANT                                   ~3      'x'
          7        SEND_VAL                                                 ~3
          8        DO_FCALL                                      0  $4      
          9        FETCH_R                      local               ~5      $4
         10        CAST                                          6  ~6      ~5
         11        ECHO                                                     ~6
         12      > RETURN                                                   1

Function f:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/jHHLP
function name:  f
number of ops:  3
compiled vars:  !0 = $x
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    5     0  E >   RECV                                             !0      
    6     1      > RETURN                                                   !0
    7     2*     > RETURN                                                   null

End of function f

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
140.5 ms | 999 KiB | 15 Q