about summary refs log tree commit diff
path: root/tests/ui/impl-trait/multiple-lifetimes/multiple-lifetimes.rs
blob: 1e949dee16f7e5eedb27f3c818875e42e7908419 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
// Test that multiple lifetimes are allowed in impl trait types.
//@ build-pass (FIXME(62277): could be check-pass?)

trait X<'x>: Sized {}

impl<U> X<'_> for U {}

fn multiple_lifeteimes<'a, 'b, T: 'static>(x: &'a mut &'b T) -> impl X<'b> + 'a {
    x
}

fn main() {}