Skip to content

Commit 2234b55

Browse files
committed
Adjust tests to new error message
1 parent 4b4c6fd commit 2234b55

7 files changed

+8
-8
lines changed

src/test/compile-fail/associated-item-duplicate-names-2.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ struct Foo;
1414

1515
impl Foo {
1616
const bar: bool = true;
17-
fn bar() {} //~ ERROR duplicate associated function
17+
fn bar() {} //~ ERROR duplicate definitions
1818
}
1919

2020
fn main() {}

src/test/compile-fail/associated-item-duplicate-names-3.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ struct Baz;
2020

2121
impl Foo for Baz {
2222
type Bar = i16;
23-
type Bar = u16; //~ ERROR duplicate associated type
23+
type Bar = u16; //~ ERROR duplicate definitions
2424
}
2525

2626
fn main() {

src/test/compile-fail/associated-item-duplicate-names.rs

+2-2
Original file line numberDiff line numberDiff line change
@@ -19,9 +19,9 @@ trait Foo {
1919

2020
impl Foo for () {
2121
type Ty = ();
22-
type Ty = usize; //~ ERROR duplicate associated type
22+
type Ty = usize; //~ ERROR duplicate definitions
2323
const BAR: u32 = 7;
24-
const BAR: u32 = 8; //~ ERROR duplicate associated constant
24+
const BAR: u32 = 8; //~ ERROR duplicate definitions
2525
}
2626

2727
fn main() {

src/test/compile-fail/impl-duplicate-methods.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
struct Foo;
1212
impl Foo {
1313
fn orange(&self){}
14-
fn orange(&self){} //~ ERROR duplicate method
14+
fn orange(&self){} //~ ERROR duplicate definitions
1515
}
1616

1717
fn main() {}

src/test/compile-fail/issue-4265.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ impl Foo {
1717
Foo { baz: 0 }.bar();
1818
}
1919

20-
fn bar() { //~ ERROR duplicate associated function
20+
fn bar() { //~ ERROR duplicate definitions
2121
}
2222
}
2323

src/test/compile-fail/issue-8153.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ trait Bar {
1818

1919
impl Bar for Foo {
2020
fn bar(&self) -> isize {1}
21-
fn bar(&self) -> isize {2} //~ ERROR duplicate method
21+
fn bar(&self) -> isize {2} //~ ERROR duplicate definitions
2222
}
2323

2424
fn main() {

src/test/compile-fail/method-macro-backtrace.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ impl S {
2929

3030
// Cause an error. It shouldn't have any macro backtrace frames.
3131
fn bar(&self) { }
32-
fn bar(&self) { } //~ ERROR duplicate method
32+
fn bar(&self) { } //~ ERROR duplicate definitions
3333
}
3434

3535
fn main() { }

0 commit comments

Comments
 (0)