Re: Planning an RFC to allow calls to global functions in constant expressions
| From: | tyson andre | Date: | Sun, 09 Feb 2020 02:40:30 +0000 |
| Subject: | Re: Planning an RFC to allow calls to global functions in constant expressions | ||
| References: | 1 | Groups: | php.internals |
| Request: | Send a blank email to internals+get-108428@lists.php.net to get a copy of this message | ||
Hi internals,
> I have a working implementation for calling global functions in constant expressions
> at https://github.com/php/php-src/pull/5139
> (see PR description for more details, see tests for how edge cases get resolved)
I've written up an early draft of this based on https://wiki.php.net/rfc/calls_in_constant_expressions
The GitHub PR hasn't yet been updated to support (and include tests for) the proposed
behavior in instance properties and in parameter defaults, but I plan to work on that.
The RFC document also includes the proposed whitelist of functions.
That document is a rough draft, and will be updated when the implementation gets updated.
- Tyson