3v4l.org

run code in 300+ PHP versions simultaneously
<?php function handler($errno, $errstr) { var_dump($errno); return false; } set_error_handler('handler', ~0); function test($string) { $string = 'bar'; } $a = 'foo'; $val = 'test'; eval($val.'(&$a);'); function_exists('error_get_last') && var_dump(error_get_last());
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 46) Position 1 = 12, Position 2 = 18
Branch analysis from position: 12
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 18
filename:       /in/RBqBK
function name:  (null)
number of ops:  19
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                                               'function_exists'
          9        SEND_VAL                                                 'error_get_last'
         10        DO_ICALL                                         $7      
         11      > JMPZ_EX                                          ~8      $7, ->18
         12    >   INIT_FCALL                                               'var_dump'
         13        INIT_FCALL                                               'error_get_last'
         14        DO_ICALL                                         $9      
         15        SEND_VAR                                                 $9
         16        DO_ICALL                                         $10     
         17        BOOL                                             ~8      $10
         18    > > RETURN                                                   1

Function handler:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/RBqBK
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                                                   <false>
    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/RBqBK
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.01 ms | 1388 KiB | 21 Q