1 2 3 4 5 6 7 8 9 10 11 12
// run-rustfix struct Foo; fn From<i32> for Foo { //~^ ERROR you might have meant to write `impl` instead of `fn` fn from(_a: i32) -> Self { Foo } } fn main() {}