-
Notifications
You must be signed in to change notification settings - Fork 13.3k
MIR borrowck: ICE: EndRegion not found #45702
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
Comments
The ICE here is caused by the assert in this function, rust/src/librustc_mir/dataflow/impls/borrows.rs Lines 126 to 134 in 563dc51
This function finds the
Right now, there is a kind of complicated assertion. It is saying that one of two things should be:
The problem is that in cases where the region never properly ends, we won't find an
So, when we are done, if |
Hi, I want to work on this bug. |
Updated tests Fixes rust-lang#45702
Fix MIR borrowck EndRegion not found Fixes #45702 - [x] Add Tests
MIR borrowck ICEs when an error involving a region whose EndRegion is missing occurs (this occurs when a region can never end within the function). Instead it should emit a correct diagnostic.
This can occur for both free regions (e.g. issue-25579):
And for infinite loops:
Causing this ICE:
The text was updated successfully, but these errors were encountered: