about summary refs log tree commit diff
path: root/tests/crashes/117392-2.rs
blob: 632ce8b9deece7c66215ea52842e4631648ab00f (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
//@ known-bug: #117392
pub trait BorrowComposite {
    type Ref<'a>: 'a;
}

impl BorrowComposite for () {
    type Ref<'a> = ();
}

pub trait Component<Args> {
    type Output;
}

impl<Args> Component<Args> for () {
    type Output = ();
}

pub fn delay<Args: BorrowComposite, Make: for<'a> FnMut(Args::Ref<'a>) -> C, C: Component<Args>>(
    make: Make,
) -> impl Component<Args> {
}

pub fn crash() -> impl Component<()> {
    delay(|()| delay(|()| ()))
}

pub fn main() {}