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

Fix redundant_clone lint not working with PathBuf and OsString #5017

Merged
merged 1 commit into from
Jan 8, 2020

Conversation

sinkuu
Copy link
Contributor

@sinkuu sinkuu commented Jan 8, 2020

#4825 diabled MIR optimization in clippy, including rustc_mir::transform::InstCombine which reduces &(*x) to x. This PR tries to unwrap &* when looking into mir::Rvalues.

Fixes #5014.


changelog: fixed redundant_clone lint not working with PathBuf and OsString

@flip1995
Copy link
Member

flip1995 commented Jan 8, 2020

@bors r+

Thanks!

@bors
Copy link
Collaborator

bors commented Jan 8, 2020

📌 Commit 99eec3f has been approved by flip1995

@bors
Copy link
Collaborator

bors commented Jan 8, 2020

⌛ Testing commit 99eec3f with merge b5c4ace...

bors added a commit that referenced this pull request Jan 8, 2020
Fix redundant_clone lint not working with PathBuf and OsString

#4825 diabled MIR optimization in clippy, including `rustc_mir::transform::InstCombine` which reduces `&(*x)` to `x`. This PR tries to unwrap `&*` when looking into `mir::Rvalue`s.

Fixes #5014.

---

changelog: fixed `redundant_clone` lint not working with `PathBuf` and `OsString`
@bors
Copy link
Collaborator

bors commented Jan 8, 2020

💔 Test failed - checks-travis

@sinkuu
Copy link
Contributor Author

sinkuu commented Jan 8, 2020

It looks like a sprious networking error.

@flip1995
Copy link
Member

flip1995 commented Jan 8, 2020

@bors retry

@bors
Copy link
Collaborator

bors commented Jan 8, 2020

⌛ Testing commit 99eec3f with merge 52b9e70...

bors added a commit that referenced this pull request Jan 8, 2020
Fix redundant_clone lint not working with PathBuf and OsString

#4825 diabled MIR optimization in clippy, including `rustc_mir::transform::InstCombine` which reduces `&(*x)` to `x`. This PR tries to unwrap `&*` when looking into `mir::Rvalue`s.

Fixes #5014.

---

changelog: fixed `redundant_clone` lint not working with `PathBuf` and `OsString`
@bors
Copy link
Collaborator

bors commented Jan 8, 2020

☀️ Test successful - checks-travis, status-appveyor
Approved by: flip1995
Pushing 52b9e70 to master...

@bors bors merged commit 99eec3f into rust-lang:master Jan 8, 2020
@sinkuu sinkuu deleted the mir_no_opt_fallout branch January 13, 2020 04:23
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.

Strange sort-of-regression in a single lint: clippy::redundant-clone
3 participants