> 
> I hear you, but what about exit; ?!
> Do not worry exit; is still supported!
> It only requires a _tiny_ bit of dark magic to achieve this!
> exit; would just be interpreted as a fetch to a constant,
> so when attempting to access the undefined exit/die case-insensitive constant
> we just need to exit as if we were calling the function!
> 

Hi Gina,

If it is mostly an implementation detail, this is probably ok. However, please 
make sure that `$foo = 'exit'; constant($foo);` (or any other future way to 
interpolate the constant) does not stop the program, but only fetch the value 
of a “real” constant.

Alternatively, it is probably possible to keep the current parsing with T_EXIT, 
but to make it equivalent to invoke a “regular” function named `exit()` — 
somehow the same way that using the backtick operator is equivalent to calling 
`shell_exec()`, up to the point that disabling `shell_exec()` will also disable 
the the backtick operator?

(BTW, it *is* currently possible to define and use a constant named “exit”: 
https://3v4l.org/aBq2R — of course, no need to keep such a “feature”.)

—Claude

Reply via email to