Skip to content

Commit caf6803

Browse files
committed
test: Fix error messages in compile-fail tests. rs=rustbot
1 parent ad02510 commit caf6803

File tree

5 files changed

+7
-12
lines changed

5 files changed

+7
-12
lines changed
+2-2
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
enum hello = int;
22

33
fn main() {
4-
let hello = 0; //~ERROR declaration of `hello` shadows an enum that's in
5-
}
4+
let hello = 0; //~ERROR declaration of `hello` shadows
5+
}

src/test/compile-fail/issue-2370-2.rs

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
1-
// error-pattern: type cat cannot be dereferenced
1+
// error-pattern: can only dereference structs
22
struct cat {
33
x: ()
44
}
55

66
fn main() {
77
let kitty : cat = cat { x: () };
88
log (error, *kitty);
9-
}
9+
}

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

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
1-
// error-pattern: type cat cannot be dereferenced
1+
// error-pattern: can only dereference structs
22
struct cat {
33
foo: ()
44
}
55

66
fn main() {
77
let nyan = cat { foo: () };
88
log (error, *nyan);
9-
}
9+
}

src/test/compile-fail/issue-2509-a.rs

-5
This file was deleted.
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
enum foo = uint;
22

33
fn main() {
4-
let (foo, _) = (2, 3); //~ ERROR declaration of `foo` shadows an enum that's in scope
4+
let (foo, _) = (2, 3); //~ ERROR declaration of `foo` shadows
55
}

0 commit comments

Comments
 (0)