Skip to content

Commit

Permalink
Adjust tests to new error message
Browse files Browse the repository at this point in the history
  • Loading branch information
aturon committed Mar 11, 2016
1 parent 4b4c6fd commit 2234b55
Show file tree
Hide file tree
Showing 7 changed files with 8 additions and 8 deletions.
2 changes: 1 addition & 1 deletion src/test/compile-fail/associated-item-duplicate-names-2.rs
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ struct Foo;

impl Foo {
const bar: bool = true;
fn bar() {} //~ ERROR duplicate associated function
fn bar() {} //~ ERROR duplicate definitions
}

fn main() {}
2 changes: 1 addition & 1 deletion src/test/compile-fail/associated-item-duplicate-names-3.rs
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ struct Baz;

impl Foo for Baz {
type Bar = i16;
type Bar = u16; //~ ERROR duplicate associated type
type Bar = u16; //~ ERROR duplicate definitions
}

fn main() {
Expand Down
4 changes: 2 additions & 2 deletions src/test/compile-fail/associated-item-duplicate-names.rs
Original file line number Diff line number Diff line change
Expand Up @@ -19,9 +19,9 @@ trait Foo {

impl Foo for () {
type Ty = ();
type Ty = usize; //~ ERROR duplicate associated type
type Ty = usize; //~ ERROR duplicate definitions
const BAR: u32 = 7;
const BAR: u32 = 8; //~ ERROR duplicate associated constant
const BAR: u32 = 8; //~ ERROR duplicate definitions
}

fn main() {
Expand Down
2 changes: 1 addition & 1 deletion src/test/compile-fail/impl-duplicate-methods.rs
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
struct Foo;
impl Foo {
fn orange(&self){}
fn orange(&self){} //~ ERROR duplicate method
fn orange(&self){} //~ ERROR duplicate definitions
}

fn main() {}
2 changes: 1 addition & 1 deletion src/test/compile-fail/issue-4265.rs
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ impl Foo {
Foo { baz: 0 }.bar();
}

fn bar() { //~ ERROR duplicate associated function
fn bar() { //~ ERROR duplicate definitions
}
}

Expand Down
2 changes: 1 addition & 1 deletion src/test/compile-fail/issue-8153.rs
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ trait Bar {

impl Bar for Foo {
fn bar(&self) -> isize {1}
fn bar(&self) -> isize {2} //~ ERROR duplicate method
fn bar(&self) -> isize {2} //~ ERROR duplicate definitions
}

fn main() {
Expand Down
2 changes: 1 addition & 1 deletion src/test/compile-fail/method-macro-backtrace.rs
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ impl S {

// Cause an error. It shouldn't have any macro backtrace frames.
fn bar(&self) { }
fn bar(&self) { } //~ ERROR duplicate method
fn bar(&self) { } //~ ERROR duplicate definitions
}

fn main() { }

0 comments on commit 2234b55

Please sign in to comment.