Skip to content

Fix clippy warnings #1890

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

Merged
merged 13 commits into from
Jun 24, 2019
Merged

Fix clippy warnings #1890

merged 13 commits into from
Jun 24, 2019

Conversation

tesuji
Copy link
Contributor

@tesuji tesuji commented Jun 5, 2019

Note: Please squash these commits before merge.

@rbtcollins
Copy link
Contributor

I have a large branch that will conflict, I think it will be easier for you to rebase and eject a couple of your clippy fixes than the other way around - please hold off on merging a couple days.

@bors
Copy link
Contributor

bors commented Jun 15, 2019

☔ The latest upstream changes (presumably #1876) made this pull request unmergeable. Please resolve the merge conflicts.

@kinnison
Copy link
Contributor

@lzutao Could you please rebase, and resubmit?

@tesuji
Copy link
Contributor Author

tesuji commented Jun 20, 2019

Sorry for the delay! I pushed new changes.

Copy link
Contributor

@kinnison kinnison left a comment

Choose a reason for hiding this comment

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

Mostly looks sane. I only commented on the first Typename -> Self conversion, but I'd like to know which lint is making that desirable because to me it's less readable in some cases, though better in others.

A suggestion is present for some of your refactoring, otherwise looks good.

@@ -95,7 +95,7 @@ impl Cfg {
);
let dist_root = dist_root_server.clone() + "/dist";

let cfg = Cfg {
let cfg = Self {
Copy link
Contributor

Choose a reason for hiding this comment

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

Is this a new lint I was previously unaware of?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I just enabled the lint in this PR.

Copy link
Contributor

Choose a reason for hiding this comment

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

Aah I see. This one is a pedantic lint and I'm not sure I completely care for it. I won't say "no" this time, but it feels a bit overly pedantic for my liking. Can make it harder to tell what something is if it's overused IMO.

@tesuji tesuji force-pushed the fix-clippy branch 2 times, most recently from 204ebbc to 408f85b Compare June 21, 2019 12:14
@tesuji
Copy link
Contributor Author

tesuji commented Jun 21, 2019

Honestly, I don't know how handler and code around that work
so I am afraid of side effect that handler could cause. But if you
are OK with this, I change it now.

@kinnison
Copy link
Contributor

The changes look good, but the build failed. And differently this time -- the dist code simply stopped by the looks of it.

@tesuji
Copy link
Contributor Author

tesuji commented Jun 22, 2019

The dist test is passed on my Azure build.

@kinnison kinnison merged commit 2ece700 into rust-lang:master Jun 24, 2019
@bors bors mentioned this pull request Jun 24, 2019
@tesuji tesuji deleted the fix-clippy branch June 24, 2019 10:49
@tesuji
Copy link
Contributor Author

tesuji commented Jun 24, 2019

Oops! You forgot to squash this PR before merging.

@kinnison
Copy link
Contributor

Oops! You forgot to squash this PR before merging.

I didn't really see a need to squash it. Each commit was clear what it was doing.

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.

4 participants