diff options
Diffstat (limited to 'src/test/compile-fail/impl-wrong-item-for-trait.rs')
| -rw-r--r-- | src/test/compile-fail/impl-wrong-item-for-trait.rs | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/src/test/compile-fail/impl-wrong-item-for-trait.rs b/src/test/compile-fail/impl-wrong-item-for-trait.rs index 9b3e28cbc01..6452e50d089 100644 --- a/src/test/compile-fail/impl-wrong-item-for-trait.rs +++ b/src/test/compile-fail/impl-wrong-item-for-trait.rs @@ -12,7 +12,9 @@ trait Foo { fn bar(&self); - const MY_CONST: u32; + //~^ NOTE original trait requirement + //~| NOTE original trait requirement + const MY_CONST: u32; //~ NOTE original trait requirement } pub struct FooConstForMethod; @@ -21,6 +23,7 @@ impl Foo for FooConstForMethod { //~^ ERROR E0046 const bar: u64 = 1; //~^ ERROR E0323 + //~| NOTE does not match trait const MY_CONST: u32 = 1; } @@ -31,6 +34,7 @@ impl Foo for FooMethodForConst { fn bar(&self) {} fn MY_CONST() {} //~^ ERROR E0324 + //~| NOTE does not match trait } pub struct FooTypeForMethod; @@ -39,6 +43,7 @@ impl Foo for FooTypeForMethod { //~^ ERROR E0046 type bar = u64; //~^ ERROR E0325 + //~| NOTE does not match trait const MY_CONST: u32 = 1; } |
