Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

False positive for C-like enums involving configuration-dependent constants #1134

Open
DemiMarie opened this issue Aug 4, 2016 · 1 comment
Labels
C-bug Category: Clippy is not doing the correct thing E-medium Call for participation: Medium difficulty level problem and requires some initial experience.

Comments

@DemiMarie
Copy link

My project includes C-like enums with discriminants that depend on the pointer width. This is done with cfg(target_pointer_width = "x") on consts. As a result, I get false positives from enum_clike_unportable_variant.

@oli-obk
Copy link
Contributor

oli-obk commented Aug 8, 2016

This probably requires rustc support to detect whether something was cfg'ed, and the cfg-message, too.

@oli-obk oli-obk added C-bug Category: Clippy is not doing the correct thing E-medium Call for participation: Medium difficulty level problem and requires some initial experience. labels Aug 8, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
C-bug Category: Clippy is not doing the correct thing E-medium Call for participation: Medium difficulty level problem and requires some initial experience.
Projects
None yet
Development

No branches or pull requests

2 participants