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 positives on unit_cmp (needs macro check) #307

Closed
llogiq opened this issue Sep 6, 2015 · 3 comments
Closed

false positives on unit_cmp (needs macro check) #307

llogiq opened this issue Sep 6, 2015 · 3 comments

Comments

@llogiq
Copy link
Contributor

llogiq commented Sep 6, 2015

If you auto-derive PartialEq or PartialOrd on a struct containing unit, this will trigger unit_cmp.

Example (from Rust, src/libcollections/string.rs:1035-1036:

#[derive(PartialEq)]
pub struct ParseError(());
@Manishearth
Copy link
Member

We should macro check this one.

@llogiq
Copy link
Contributor Author

llogiq commented Sep 6, 2015

Yes. I already wrote that in the title.

@Manishearth
Copy link
Member

Oh, wow, I'm an idiot 😝

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants