2019-10-03 13:41:27 -05:00
|
|
|
trait Foo {
|
|
|
|
fn foo<'a>(x: &i32, y: &'a i32) -> &'a i32;
|
|
|
|
}
|
|
|
|
|
|
|
|
impl Foo for () {
|
|
|
|
fn foo<'a>(x: &'a i32, y: &'a i32) -> &'a i32 {
|
2019-10-03 22:14:48 -05:00
|
|
|
//~^ ERROR `impl` item signature doesn't match `trait` item signature
|
2019-10-03 13:41:27 -05:00
|
|
|
if x > y { x } else { y }
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
fn main() {}
|