diff options
author | Nikita Popov <nikita.ppv@gmail.com> | 2020-06-15 11:50:55 +0200 |
---|---|---|
committer | Nikita Popov <nikita.ppv@gmail.com> | 2020-07-22 12:36:05 +0200 |
commit | 7a3dcc3e339cde2177ba4fe8fc45f78c94dfbb29 (patch) | |
tree | 7750f94dceba15437e3dad497734d3b1d65b4e4b /UPGRADING | |
parent | acbf7802af7b88d16497971494f5dc42c4e08ce6 (diff) | |
download | php-git-7a3dcc3e339cde2177ba4fe8fc45f78c94dfbb29.tar.gz |
Treat namespaced names as single token
Namespace names are now lexed as single tokens of type
T_NAME_QUALIFIED, T_NAME_FULLY_QUALIFIED or T_NAME_RELATIVE.
RFC: https://wiki.php.net/rfc/namespaced_names_as_token
Closes GH-5827.
Diffstat (limited to 'UPGRADING')
-rw-r--r-- | UPGRADING | 9 |
1 files changed, 9 insertions, 0 deletions
@@ -204,6 +204,10 @@ PHP 8.0 UPGRADE NOTES numbers and numeric strings continue to work as before. Notably, this means that `0 == "not-a-number"` is considered false now. RFC: https://wiki.php.net/rfc/string_to_number_comparison + . Namespaced names can no longer contain whitespace: While `Foo\Bar` will be + recognized as a namespaced name, `Foo \ Bar` will not. Conversely, reserved + keywords are now permitted as namespace segments. + RFC: https://wiki.php.net/rfc/namespaced_names_as_token - COM: . Removed the ability to import case-insensitive constants from type @@ -509,6 +513,11 @@ PHP 8.0 UPGRADE NOTES instead be part of a following T_WHITESPACE token. It should be noted that T_COMMENT is not always followed by whitespace, it may also be followed by T_CLOSE_TAG or end-of-file. + . Namespaced names are now represented using the T_NAME_QUALIFIED (Foo\Bar), + T_NAME_FULLY_QUALIFIED (\Foo\Bar) and T_NAME_RELATIVE (namespace\Foo\Bar) + tokens. T_NS_SEPARATOR is only used for standalone namespace separators, + and only syntactially valid in conjunction with group use declarations. + RFC: https://wiki.php.net/rfc/namespaced_names_as_token - XML: . xml_parser_create(_ns) will now return an XmlParser object rather than a |