-
Notifications
You must be signed in to change notification settings - Fork 13k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Don't ICE in is_trivially_sized when encountering late-bound self ty
- Loading branch information
1 parent
c57393e
commit c31aedf
Showing
3 changed files
with
32 additions
and
2 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
19 changes: 19 additions & 0 deletions
19
tests/ui/traits/non_lifetime_binders/sized-late-bound-issue-114872.rs
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,19 @@ | ||
// check-pass | ||
|
||
#![feature(non_lifetime_binders)] | ||
//~^ WARN is incomplete and may not be safe | ||
|
||
pub fn foo() | ||
where | ||
for<V> V: Sized, | ||
{ | ||
bar(); | ||
} | ||
|
||
pub fn bar() | ||
where | ||
for<V> V: Sized, | ||
{ | ||
} | ||
|
||
pub fn main() {} |
11 changes: 11 additions & 0 deletions
11
tests/ui/traits/non_lifetime_binders/sized-late-bound-issue-114872.stderr
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,11 @@ | ||
warning: the feature `non_lifetime_binders` is incomplete and may not be safe to use and/or cause compiler crashes | ||
--> $DIR/sized-late-bound-issue-114872.rs:3:12 | ||
| | ||
LL | #![feature(non_lifetime_binders)] | ||
| ^^^^^^^^^^^^^^^^^^^^ | ||
| | ||
= note: see issue #108185 <https://github.com/rust-lang/rust/issues/108185> for more information | ||
= note: `#[warn(incomplete_features)]` on by default | ||
|
||
warning: 1 warning emitted | ||
|