Skip to content

Clear some clippy::pedantic pings#120

Merged
philiptaron merged 4 commits intoNixOS:mainfrom
Ben-PH:contrib
Oct 28, 2024
Merged

Clear some clippy::pedantic pings#120
philiptaron merged 4 commits intoNixOS:mainfrom
Ben-PH:contrib

Conversation

@Ben-PH
Copy link
Copy Markdown
Contributor

@Ben-PH Ben-PH commented Oct 28, 2024

This PR is probably one (tiny) step above scraping doc-comments and passing it through a spell-checker. I just ran clippy with #![warn(clippy::pedantic)], clearing the lints and/or specifically allowing lints until it was clear. I just hope this is a net positive for you.

I noticed this project mentioned in the nixconf recording, and thought I'd have a look. This is a first-pass, and would be happy to provide more substantive PRs.

@Ben-PH Ben-PH marked this pull request as ready for review October 28, 2024 09:55
Copy link
Copy Markdown
Contributor

@philiptaron philiptaron left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good to me other than the one highlighted spot. Thank you for the contribution!

cargo fmt needs to be run as well, as CI highlights.

src/eval.rs Outdated
| (false, Some(_))
// Something like `<attr> = bar` where `bar = pkgs.callPackage ...`
| (true, None) => {
(_, None) | (false, Some(_)) => {
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please revert or find another way of expressing the comments, like extracting to a function or something. Humans are bad at understanding what the _ in these expressions actually means in nixpkgs already, and the removal of the comments makes it much worse. I'd much rather have a longer function than to miss this.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

done: 5b4aae3

@Ben-PH
Copy link
Copy Markdown
Contributor Author

Ben-PH commented Oct 28, 2024

format done, requested change reversion done. Appologies for the skipped fmt.

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

Successfully merging this pull request may close these issues.

2 participants