You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Add invisible open delimiters to TokenDescription.
Invisible delimiters pretty-print as empty strings, and changing that
can break some proc macros. But error messages saying "expected
identifer, found ``" are bad. So this commit adds support for invisible
open delimiters in `TokenDescription` so they print as "invisible open
delimiter" in error messages, instead of "``".
It's not used meaningfully yet, but will be needed to get rid of interpolated
tokens.
parse_expected_semi_found_doc_comment_str = expected `;`, found doc comment `{$token}`
222
+
# Deliberately doesn't print `$token`, which is empty.
223
+
parse_expected_semi_found_invisible_open_delim_str = expected `;`, found invisible open delimiter
219
224
parse_expected_semi_found_keyword_str = expected `;`, found keyword `{$token}`
220
225
parse_expected_semi_found_reserved_identifier_str = expected `;`, found reserved identifier `{$token}`
221
226
parse_expected_semi_found_reserved_keyword_str = expected `;`, found reserved keyword `{$token}`
@@ -797,6 +802,8 @@ parse_unexpected_token_after_not_default = use `!` to perform logical negation o
797
802
parse_unexpected_token_after_not_logical = use `!` to perform logical negation
798
803
parse_unexpected_token_after_struct_name = expected `where`, `{"{"}`, `(`, or `;` after struct name
799
804
parse_unexpected_token_after_struct_name_found_doc_comment = expected `where`, `{"{"}`, `(`, or `;` after struct name, found doc comment `{$token}`
805
+
# Deliberately doesn't print `$token`, which is empty.
806
+
parse_unexpected_token_after_struct_name_found_invisible_open_delim = expected `where`, `{"{"}`, `(`, or `;` after struct name, found invisible open delim
800
807
parse_unexpected_token_after_struct_name_found_keyword = expected `where`, `{"{"}`, `(`, or `;` after struct name, found keyword `{$token}`
801
808
parse_unexpected_token_after_struct_name_found_other = expected `where`, `{"{"}`, `(`, or `;` after struct name, found `{$token}`
0 commit comments