fork/rust
git clone https://git.julia.blue/fork/rust
3bcad65fbf6
master
1error[E0053]: method `call` has an incompatible type for trait 2 --> $DIR/issue-20225.rs:6:43 3 | 4LL | impl<'a, T> Fn<(&'a T,)> for Foo { 5 | - this type parameter 6LL | extern "rust-call" fn call(&self, (_,): (T,)) {} 7 | ^^^^ 8 | | 9 | expected `&'a T`, found type parameter `T` 10 | help: change the parameter type to match the trait: `(&'a T,)` 11 | 12 = note: expected signature `extern "rust-call" fn(&Foo, (&'a T,))` 13 found signature `extern "rust-call" fn(&Foo, (T,))` 14 15error[E0053]: method `call_mut` has an incompatible type for trait 16 --> $DIR/issue-20225.rs:11:51 17 | 18LL | impl<'a, T> FnMut<(&'a T,)> for Foo { 19 | - this type parameter 20LL | extern "rust-call" fn call_mut(&mut self, (_,): (T,)) {} 21 | ^^^^ 22 | | 23 | expected `&'a T`, found type parameter `T` 24 | help: change the parameter type to match the trait: `(&'a T,)` 25 | 26 = note: expected signature `extern "rust-call" fn(&mut Foo, (&'a T,))` 27 found signature `extern "rust-call" fn(&mut Foo, (T,))` 28 29error[E0053]: method `call_once` has an incompatible type for trait 30 --> $DIR/issue-20225.rs:18:47 31 | 32LL | impl<'a, T> FnOnce<(&'a T,)> for Foo { 33 | - this type parameter 34... 35LL | extern "rust-call" fn call_once(self, (_,): (T,)) {} 36 | ^^^^ 37 | | 38 | expected `&'a T`, found type parameter `T` 39 | help: change the parameter type to match the trait: `(&'a T,)` 40 | 41 = note: expected signature `extern "rust-call" fn(Foo, (&'a T,))` 42 found signature `extern "rust-call" fn(Foo, (T,))` 43 44error: aborting due to 3 previous errors 45 46For more information about this error, try `rustc --explain E0053`.