Skip to content

Commit 425ed6f

Browse files
committed
Check help message in the test
1 parent 6ea8e79 commit 425ed6f

File tree

2 files changed

+5
-2
lines changed

2 files changed

+5
-2
lines changed

tests/ui/error-codes/E0050.rs

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,8 +8,11 @@ struct Bar;
88

99
impl Foo for Bar {
1010
fn foo(&self) -> bool { true } //~ ERROR E0050
11+
//~| HELP: modify the signature to match the trait definition
1112
fn bar(&self) { } //~ ERROR E0050
13+
//~| HELP: modify the signature to match the trait definition
1214
fn less(&self, x: u8, y: u8, z: u8) { } //~ ERROR E0050
15+
//~| HELP: modify the signature to match the trait definition
1316
}
1417

1518
fn main() {

tests/ui/error-codes/E0050.stderr

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ LL | fn foo(&self, x: u8) -> bool { true }
1313
| +++++++
1414

1515
error[E0050]: method `bar` has 1 parameter but the declaration in trait `Foo::bar` has 4
16-
--> $DIR/E0050.rs:11:12
16+
--> $DIR/E0050.rs:12:12
1717
|
1818
LL | fn bar(&self, x: u8, y: u8, z: u8);
1919
| -------------------------- trait requires 4 parameters
@@ -27,7 +27,7 @@ LL | fn bar(&self, x: u8, y: u8, z: u8) { }
2727
| +++++++++++++++++++++
2828

2929
error[E0050]: method `less` has 4 parameters but the declaration in trait `Foo::less` has 1
30-
--> $DIR/E0050.rs:12:13
30+
--> $DIR/E0050.rs:14:13
3131
|
3232
LL | fn less(&self);
3333
| ----- trait requires 1 parameter

0 commit comments

Comments
 (0)