blob: 9cbafc716b5000dc2bd4ac51904fa90369df037a (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
|
//! This is a reproducer for the ICE 6792: https://github.com/rust-lang/rust-clippy/issues/6792.
//! The ICE is caused by using `TyCtxt::type_of(assoc_type_id)`.
trait Trait {
type Ty;
fn broken() -> Self::Ty;
}
struct Foo;
impl Trait for Foo {
type Ty = Foo;
fn broken() -> Self::Ty {
Self::Ty {}
}
}
fn main() {}
|