diff --git a/src/test/compile-fail/struct-no-fields-2.rs b/src/test/compile-fail/struct-no-fields-2.rs index b6a40a0e8e9..63e38e35447 100644 --- a/src/test/compile-fail/struct-no-fields-2.rs +++ b/src/test/compile-fail/struct-no-fields-2.rs @@ -8,11 +8,11 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -// error-pattern: Unit-like struct construction is written with no trailing `{ }` struct Foo; fn f2() { let _end_stmt = Foo { }; + //~^ ERROR: Unit-like struct construction is written with no trailing `{ }` } fn main() {} diff --git a/src/test/compile-fail/struct-no-fields-3.rs b/src/test/compile-fail/struct-no-fields-3.rs index b6845ce7292..33077d4f1b3 100644 --- a/src/test/compile-fail/struct-no-fields-3.rs +++ b/src/test/compile-fail/struct-no-fields-3.rs @@ -8,11 +8,11 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -// error-pattern: Unit-like struct construction is written with no trailing `{ }` struct Foo; fn g3() { let _mid_tuple = (Foo { }, 2); + //~^ ERROR: Unit-like struct construction is written with no trailing `{ }` } fn main() {} diff --git a/src/test/compile-fail/struct-no-fields-4.rs b/src/test/compile-fail/struct-no-fields-4.rs index 0bd3c8d5855..6b73cb769ee 100644 --- a/src/test/compile-fail/struct-no-fields-4.rs +++ b/src/test/compile-fail/struct-no-fields-4.rs @@ -8,11 +8,11 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -// error-pattern: Unit-like struct construction is written with no trailing `{ }` struct Foo; fn h4() { let _end_of_tuple = (3, Foo { }); + //~^ ERROR: Unit-like struct construction is written with no trailing `{ }` } fn main() {} diff --git a/src/test/compile-fail/struct-no-fields-5.rs b/src/test/compile-fail/struct-no-fields-5.rs index 1af72ff6d78..81c050e61cb 100644 --- a/src/test/compile-fail/struct-no-fields-5.rs +++ b/src/test/compile-fail/struct-no-fields-5.rs @@ -8,11 +8,11 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -// error-pattern: Unit-like struct construction is written with no trailing `{ }` struct Foo; fn i5() { let _end_of_block = { Foo { } }; + //~^ ERROR: Unit-like struct construction is written with no trailing `{ }` } fn main() {} diff --git a/src/test/compile-fail/struct-no-fields.rs b/src/test/compile-fail/struct-no-fields.rs index 5053b842e65..6142ec0653c 100644 --- a/src/test/compile-fail/struct-no-fields.rs +++ b/src/test/compile-fail/struct-no-fields.rs @@ -8,7 +8,7 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -// error-pattern: Unit-like struct definition should be written as `struct Foo;` struct Foo {} +//~^ ERROR: Unit-like struct definition should be written as `struct Foo;` fn main() {}