]>
Commit | Line | Data |
---|---|---|
6a06907d XL |
1 | // failure-status: 101 |
2 | // rustc-env:RUST_BACKTRACE=0 | |
3 | // normalize-stderr-test "note: .*\n\n" -> "" | |
4 | // normalize-stderr-test "thread 'rustc' panicked.*\n" -> "" | |
5 | ||
6 | // compile-flags: --crate-type=rlib | |
7 | ||
8 | // Regression test for https://github.com/rust-lang/rust/issues/78450 | |
9 | ||
10 | #![feature(min_type_alias_impl_trait)] | |
11 | #![no_std] | |
12 | ||
13 | pub trait AssociatedImpl { | |
14 | type ImplTrait; | |
15 | ||
16 | fn f() -> Self::ImplTrait; | |
17 | } | |
18 | ||
19 | struct S<T>(T); | |
20 | ||
21 | trait Associated { | |
22 | type A; | |
23 | } | |
24 | ||
25 | // ICE | |
26 | impl<'a, T: Associated<A = &'a ()>> AssociatedImpl for S<T> { | |
27 | type ImplTrait = impl core::fmt::Debug; | |
28 | ||
29 | fn f() -> Self::ImplTrait { | |
30 | //~^ ERROR unexpected concrete region in borrowck: ReEarlyBound(0, 'a) | |
31 | () | |
32 | } | |
33 | } |