-
Notifications
You must be signed in to change notification settings - Fork 30
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
Move DmFlags definition into separate module #287
Conversation
clippy failure. |
@agrover review, please? |
clippy should pass this time. |
And it does! @agrover review, please? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
just a few questions around allow()s and a comment block
src/dm.rs
Outdated
@@ -6,8 +6,6 @@ | |||
// Their scope is the whole file because the bitflags! macro generates a | |||
// lot of stuff, and so placing the annotation right on the use of the | |||
// bitflags! macro does not actually cover the suspicious code generated. | |||
#![allow(redundant_field_names)] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
the preceding comment is copied in the new file, can it be removed from here?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes.
src/dm_flags.rs
Outdated
// License, v. 2.0. If a copy of the MPL was not distributed with this | ||
// file, You can obtain one at http://mozilla.org/MPL/2.0/. | ||
|
||
// These errors originate in bitflags! macro and are not ours to fix. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Are these clippy errors or regular rustc errors? Just curious. Might be nice to say.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Still an issue with most recent bitflags crate?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The most recent bitflags crate hasn't changed since these clippy errors were added.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
These must be clippy errors, because we use clippy annotations to ignore them.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
clippy has changed, though, so it may be possible to remove a lint or two: bitflags/bitflags#149. I'm going to give it a try.
755300d
to
bf610c8
Compare
To make dm module a bit shorter. To avoid a circular dependency between deviceinfo and dm modules. Rust supports circular dependencies, obviously, but too many is a sign of poor modularity. Remove the clippy lints, since the recent version of clippy doesn't warn anymore. Signed-off-by: mulhern <amulhern@redhat.com>
bf610c8
to
23edea8
Compare
@agrover review? Turns out clippy change means those two lints aren't triggered by bitflags! generated code, so the whole clippy thing can go away. |
No description provided.