-
-
Notifications
You must be signed in to change notification settings - Fork 15k
underscore_literal_suffix future-compatibility warnings #42326
Copy link
Copy link
Closed
Labels
B-unstableBlocker: Implemented in the nightly compiler and unstable.Blocker: Implemented in the nightly compiler and unstable.C-future-incompatibilityCategory: Future-incompatibility lintsCategory: Future-incompatibility lintsC-tracking-issueCategory: An issue tracking the progress of sth. like the implementation of an RFCCategory: An issue tracking the progress of sth. like the implementation of an RFCT-compilerRelevant to the compiler team, which will review and decide on the PR/issue.Relevant to the compiler team, which will review and decide on the PR/issue.
Metadata
Metadata
Assignees
Labels
B-unstableBlocker: Implemented in the nightly compiler and unstable.Blocker: Implemented in the nightly compiler and unstable.C-future-incompatibilityCategory: Future-incompatibility lintsCategory: Future-incompatibility lintsC-tracking-issueCategory: An issue tracking the progress of sth. like the implementation of an RFCCategory: An issue tracking the progress of sth. like the implementation of an RFCT-compilerRelevant to the compiler team, which will review and decide on the PR/issue.Relevant to the compiler team, which will review and decide on the PR/issue.
Type
Fields
Give feedbackNo fields configured for issues without a type.
This is the summary issue for the
UNDERSCORE_LITERAL_SUFFIXfuture-compatibility warning and other related errors. The goal of this page is describe why this change was made and how you can fixcode that is affected by it. It also provides a place to ask questions or register a complaint if you feel the change should not be made.
What is the warning for?
The
underscore_literal_suffixwarning is issued when you use_as a literal suffix. Due to the behavior of the lexer, this is limited to these two situations:"Foo"_.:1._(this kind of construction is already banned by means of Disallow ._ in float literal. #41946)This warning can always be fixed by removing the
_and inserting whitespaces if necessary.When will this warning become a hard error?
At the beginning of each 6-week release cycle, the Rust compiler team
will review the set of outstanding future compatibility warnings and
nominate some of them for Final Comment Period. Toward the end of
the cycle, we will review any comments and make a final determination
whether to convert the warning into a hard error or remove it
entirely.