3v4l.org

run code in 300+ PHP versions simultaneously
<?php function dangerous() { echo 'Dangerous code executed'; } $string = '{$x = dangerous()}'; preg_replace('/(.+)/e', '"$1"', $string);
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/o1jpd
function name:  (null)
number of ops:  7
compiled vars:  !0 = $string
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    8     0  E >   ASSIGN                                                   !0, '%7B%24x+%3D+dangerous%28%29%7D'
    9     1        INIT_FCALL                                               'preg_replace'
          2        SEND_VAL                                                 '%2F%28.%2B%29%2Fe'
          3        SEND_VAL                                                 '%22%241%22'
          4        SEND_VAR                                                 !0
          5        DO_ICALL                                                 
          6      > RETURN                                                   1

Function dangerous:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/o1jpd
function name:  dangerous
number of ops:  2
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    5     0  E >   ECHO                                                     'Dangerous+code+executed'
    6     1      > RETURN                                                   null

End of function dangerous

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
153.56 ms | 1385 KiB | 15 Q