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 a lifetime bug uncovered by NLL, thanks @lqd #454

Merged
merged 1 commit into from
Jul 5, 2018
Merged

Fix a lifetime bug uncovered by NLL, thanks @lqd #454

merged 1 commit into from
Jul 5, 2018

Conversation

SimonSapin
Copy link
Member

@SimonSapin SimonSapin commented Jul 4, 2018

A similar error message was: https://play.rust-lang.org/?gist=4c5f4002623da9a3df723c9540dd125e&version=nightly&mode=debug&edition=2015

error[E0509]: cannot move out of type `S<'_>`, which implements the `Drop` trait
  --> src/main.rs:15:17
   |
15 |         let S { url } = self;
   |                 ^^^ cannot move out of here

This change is Reviewable

@nox
Copy link
Contributor

nox commented Jul 5, 2018

@bors-servo r+

@bors-servo
Copy link
Contributor

📌 Commit 2efa106 has been approved by nox

@bors-servo
Copy link
Contributor

⌛ Testing commit 2efa106 with merge 555f275...

bors-servo pushed a commit that referenced this pull request Jul 5, 2018
Fix a lifetime bug uncovered by NLL, thanks @lqd

A similar error message was: https://play.rust-lang.org/?gist=4c5f4002623da9a3df723c9540dd125e&version=nightly&mode=debug&edition=2015

```rust
error[E0509]: cannot move out of type `S<'_>`, which implements the `Drop` trait
  --> src/main.rs:15:17
   |
15 |         let S { url } = self;
   |                 ^^^ cannot move out of here
```

<!-- Reviewable:start -->
---
This change is [<img src="https://reviewable.io/review_button.svg" height="34" align="absmiddle" alt="Reviewable"/>](https://reviewable.io/reviews/servo/rust-url/454)
<!-- Reviewable:end -->
@bors-servo
Copy link
Contributor

☀️ Test successful - status-travis
Approved by: nox
Pushing 555f275 to master...

@bors-servo bors-servo merged commit 2efa106 into master Jul 5, 2018
@lqd
Copy link

lqd commented Jul 5, 2018

BTW I've also filed a diagnostics issue for the less-than-clear error message shown for the original code rust-lang/rust#52059

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