-
-
Notifications
You must be signed in to change notification settings - Fork 14.9k
unexpected_cfgs lint doesn't recognize some standard cfgs #124816
Copy link
Copy link
Open
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.C-discussionCategory: Discussion or questions that doesn't represent real issues.Category: Discussion or questions that doesn't represent real issues.L-unexpected_cfgsLint: unexpected_cfgsLint: unexpected_cfgsT-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
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.C-discussionCategory: Discussion or questions that doesn't represent real issues.Category: Discussion or questions that doesn't represent real issues.L-unexpected_cfgsLint: unexpected_cfgsLint: unexpected_cfgsT-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.
As part of google/zerocopy#1204, I discovered that the
unexpected_cfgslint fires on some standardcfgs that are common in the ecosystem. The two I discovered so far are:doc_cfgkani(used by the Kani verifier)I've had to manually emit directives for these. It's not that onerous, but I could imagine it getting onerous especially for projects that don't already have a
build.rsscript.It would be good if the lint could be taught about some of the standard
cfgs in the ecosystem to cut down on the noise.