-
Notifications
You must be signed in to change notification settings - Fork 12.8k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
allow escaping bound vars when normalizing
ty::Opaque
- Loading branch information
Showing
3 changed files
with
17 additions
and
9 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
// build-pass | ||
|
||
// This used to fail MIR validation due to the types on both sides of | ||
// an assignment not being equal. | ||
// The failure doesn't occur with a check-only build. | ||
|
||
fn iter_slice<'a, T>(xs: &'a [T]) -> impl Iterator<Item = &'a T> { | ||
xs.iter() | ||
} | ||
|
||
fn main() { | ||
iter_slice::<()> as fn(_) -> _; | ||
} |