summaryrefslogtreecommitdiffstats
path: root/src/test/ui/lifetimes/shadow.rs
blob: e2124887e0f091735c33dc699dba5fadcecf0fae (plain)
1
2
3
4
5
6
7
8
struct Foo<T>(T);

impl<'s> Foo<&'s u8> {
    fn bar<'s>(&self, x: &'s u8) {} //~ ERROR shadows a lifetime name
    fn baz(x: for<'s> fn(&'s u32)) {} //~ ERROR shadows a lifetime name
}

fn main() {}