-
-
Notifications
You must be signed in to change notification settings - Fork 14.7k
Wrong "unnecessary parentheses around function argument"-warning #47775
Copy link
Copy link
Closed
Labels
A-lintsArea: Lints (warnings about flaws in source code) such as unused_mut.Area: Lints (warnings about flaws in source code) such as unused_mut.P-highHigh priorityHigh priorityT-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.regression-from-stable-to-nightlyPerformance or correctness regression from stable to nightly.Performance or correctness regression from stable to nightly.
Metadata
Metadata
Assignees
Labels
A-lintsArea: Lints (warnings about flaws in source code) such as unused_mut.Area: Lints (warnings about flaws in source code) such as unused_mut.P-highHigh priorityHigh priorityT-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.regression-from-stable-to-nightlyPerformance or correctness regression from stable to nightly.Performance or correctness regression from stable to nightly.
Type
Fields
Give feedbackNo fields configured for issues without a type.
Recent nightly versions give warnings when using the macro
do_parse!()of nom:I tried this code:
I expected to see this happen:
No warning.
Instead, this happened:
After investigating this further I found the source of the warning (see SWW13/nom@f1a04eb#diff-06e70f2a187023418eedf26d22d3aa5d).
But these parentheses are needed for the additional tuple, removing them breaks the
nomtests.CI logs show last working version
rustc 1.25.0-nightly (da569fa9d 2018-01-16)and first broken versionrustc 1.25.0-nightly (97520ccb1 2018-01-21).Meta
Related Issue: rust-bakery/nom#668
rustc --version --verbose: