On 29/01/2017 19:33, Rowan Collins wrote:
Currently, if the constant FROB_ACTIVE is not defined, the code "echo
FROB_ACTIVE;" results in an E_NOTICE and the string 'FROB_ACTIVE'
being displayed. I would like to propose that this be changed to an
E_WARNING in PHP 7.2, and to an Error in PHP 8.0.
[...]
https://wiki.php.net/rfc/deprecate-bareword-strings
Hi,
I have made some minor updates to the above RFC, and would like to open
it for voting in the next few days.
Changes since I first posted the RFC are:
- Expanded the rationale for using E_WARNING rather than E_DEPRECATED. I
always anticipated this would be the most contentious part of the
proposal, but am convinced the peculiarities of the situation make this
the best choice. Please read that section carefully if you are
concerned, and let me know if anything remains unclear.
- Settled on a proposed wording for the new Warning. I spent some time
considering the best phrasing and punctuation, but if anyone would like
to suggest an improvement, I am open to feedback.
- Clarified the history of the feature, having successfully built PHP 2
from the archived source, and confirmed that bare words were a syntax
error. As such, no non-beta version of PHP allowed unquoted strings
without issuing a Notice.
- Added links to Pull Requests for both php-src and php-langspec to
implement the proposed wording. Amusingly, I had to change a test in
php-src which seems to have been *accidentally* using an unquoted
string; apparently, the configuration of that test is such that the
E_NOTICE was suppressed.
Please let me know if there is any feedback I should take into
consideration before opening this to a vote.
Regards,
--
Rowan Collins
[IMSoP]
--
PHP Internals - PHP Runtime Development Mailing List
To unsubscribe, visit: http://www.php.net/unsub.php