summaryrefslogtreecommitdiffstats
path: root/tests/ui/impl-trait/extra-impl-in-trait-impl.rs
blob: 024b703e6f23549103d0170724892b7b5c8a4f9c (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
// run-rustfix

struct S<T>(T);
struct S2;

impl<T: Default> impl Default for S<T> {
    //~^ ERROR: unexpected `impl` keyword
    //~| HELP: remove the extra `impl`
    fn default() -> Self { todo!() }
}

impl impl Default for S2 {
    //~^ ERROR: unexpected `impl` keyword
    //~| HELP: remove the extra `impl`
    fn default() -> Self { todo!() }
}


fn main() {}