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

Overlapping borrows can point to different lvalues. #44999

Merged
merged 1 commit into from
Oct 4, 2017

Conversation

pnkfelix
Copy link
Member

@pnkfelix pnkfelix commented Oct 3, 2017

Overlapping borrows can point to different lvalues.

There's always a basis for the overlap, so instead of removing the assert entirely, I instead pass in the prefix that we found and check that it actually is a prefix of both lvalues.

Fix #44829

There's always a basis for the overlap, so instead of removing the
assert entirely, I instead pass in the prefix that we found and check
that it actually is a prefix of both lvalues.

Fix rust-lang#44829
@rust-highfive
Copy link
Collaborator

r? @nikomatsakis

(rust_highfive has picked a reviewer for you, use r? to override)

@pnkfelix
Copy link
Member Author

pnkfelix commented Oct 3, 2017

fyi this is going to collide with the merge of #44882; its easy to deal with and I'll update the PR after that lands.

@nikomatsakis
Copy link
Contributor

@bors r+

@bors
Copy link
Contributor

bors commented Oct 3, 2017

📌 Commit aac64c4 has been approved by nikomatsakis

@bors
Copy link
Contributor

bors commented Oct 4, 2017

⌛ Testing commit aac64c4 with merge f1938cf...

bors added a commit that referenced this pull request Oct 4, 2017
…=nikomatsakis

Overlapping borrows can point to different lvalues.

Overlapping borrows can point to different lvalues.

There's always a basis for the overlap, so instead of removing the assert entirely, I instead pass in the prefix that we found and check that it actually is a prefix of both lvalues.

Fix #44829
@bors
Copy link
Contributor

bors commented Oct 4, 2017

☀️ Test successful - status-appveyor, status-travis
Approved by: nikomatsakis
Pushing f1938cf to master...

@bors bors merged commit aac64c4 into rust-lang:master Oct 4, 2017
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.

MIR-borrowck: ICE: assertion failure left == right
4 participants