about summary refs log tree commit diff
path: root/tests/ui/issues/issue-17740.rs
blob: 20a73756ea3ea5b096564162611560bfb21062f0 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
//@ dont-require-annotations: NOTE

struct Foo<'a> {
    data: &'a[u8],
}

impl <'a> Foo<'a>{
    fn bar(self: &mut Foo) {
    //~^ ERROR mismatched `self` parameter type
    //~| NOTE expected struct `Foo<'a>`
    //~| NOTE found struct `Foo<'_>`
    //~| NOTE lifetime mismatch
    //~| ERROR mismatched `self` parameter type
    //~| NOTE expected struct `Foo<'a>`
    //~| NOTE found struct `Foo<'_>`
    //~| NOTE lifetime mismatch
    }
}

fn main() {}