Skip to content

verbose_bit_mask #1940

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

Closed
hongxuchen opened this issue Aug 9, 2017 · 4 comments
Closed

verbose_bit_mask #1940

hongxuchen opened this issue Aug 9, 2017 · 4 comments
Labels
C-bug Category: Clippy is not doing the correct thing good-first-issue These issues are a good way to get started with Clippy T-middle Type: Probably requires verifiying types

Comments

@hongxuchen
Copy link

Correct me if I'm wrong, but for x = 0b10000u16, x.trailing_zeros() > 4 and x & 0b1111 == 0 are not equivalent. Shouldn't the advice be >=?

@oli-obk oli-obk added good-first-issue These issues are a good way to get started with Clippy C-bug Category: Clippy is not doing the correct thing T-middle Type: Probably requires verifiying types labels Aug 9, 2017
@mati865
Copy link
Contributor

mati865 commented Aug 13, 2017

@hongxuchen do you want to fix it yourself?

@hongxuchen
Copy link
Author

@mati865 seems you've made it, and thanks!

@mati865
Copy link
Contributor

mati865 commented Aug 13, 2017

@hongxuchen I'm just playing around (it's another way to learn language).
You can open PR with fix if you want to be mentioned as contributor.

@hongxuchen
Copy link
Author

@mati865 it's okay you open PR with your fix 😄

mati865 added a commit to mati865/rust-clippy that referenced this issue Aug 13, 2017
mati865 added a commit to mati865/rust-clippy that referenced this issue Aug 14, 2017
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 good-first-issue These issues are a good way to get started with Clippy T-middle Type: Probably requires verifiying types
Projects
None yet
Development

No branches or pull requests

3 participants