3v4l.org

run code in 300+ PHP versions simultaneously
<?php function handler($errno, $errstr) { var_dump($errno); return true; } set_error_handler('handler', ~0); function test($string) { $string = 'bar'; } $a = 'foo'; $val = 'test'; eval($val.'(&$a);'); var_dump(error_get_last());
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/cDKW2
function name:  (null)
number of ops:  14
compiled vars:  !0 = $a, !1 = $val
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    6     0  E >   INIT_FCALL                                               'set_error_handler'
          1        SEND_VAL                                                 'handler'
          2        SEND_VAL                                                 -1
          3        DO_ICALL                                                 
   11     4        ASSIGN                                                   !0, 'foo'
   12     5        ASSIGN                                                   !1, 'test'
   13     6        CONCAT                                           ~5      !1, '%28%26%24a%29%3B'
          7        INCLUDE_OR_EVAL                                          ~5, EVAL
   14     8        INIT_FCALL                                               'var_dump'
          9        INIT_FCALL                                               'error_get_last'
         10        DO_ICALL                                         $7      
         11        SEND_VAR                                                 $7
         12        DO_ICALL                                                 
         13      > RETURN                                                   1

Function handler:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/cDKW2
function name:  handler
number of ops:  7
compiled vars:  !0 = $errno, !1 = $errstr
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    2     0  E >   RECV                                             !0      
          1        RECV                                             !1      
    3     2        INIT_FCALL                                               'var_dump'
          3        SEND_VAR                                                 !0
          4        DO_ICALL                                                 
    4     5      > RETURN                                                   <true>
    5     6*     > RETURN                                                   null

End of function handler

Function test:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/cDKW2
function name:  test
number of ops:  3
compiled vars:  !0 = $string
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    7     0  E >   RECV                                             !0      
    9     1        ASSIGN                                                   !0, 'bar'
   10     2      > RETURN                                                   null

End of function test

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
151.55 ms | 1396 KiB | 19 Q