about summary refs log tree commit diff
path: root/src/test
diff options
context:
space:
mode:
authorbors <bors@rust-lang.org>2017-01-26 12:23:13 +0000
committerbors <bors@rust-lang.org>2017-01-26 12:23:13 +0000
commit07fe04c1e2d66cfc351ffa69157facc7d8a819cd (patch)
tree13f6d5c81c36807de55a3bb4e6bf3b97dc86ace4 /src/test
parent5158501367de00d0b639a7840fba958f8da2f3c6 (diff)
parent97b9c8b8d37ec21212d9c54ae510eae0220fbf7e (diff)
downloadrust-07fe04c1e2d66cfc351ffa69157facc7d8a819cd.tar.gz
rust-07fe04c1e2d66cfc351ffa69157facc7d8a819cd.zip
Auto merge of #38819 - GuillaumeGomez:main_func_wrong_type, r=GuillaumeGomez
Add a distinct error code and description for "main function has wron…

…g type"
Diffstat (limited to 'src/test')
-rw-r--r--src/test/compile-fail/E0580.rs (renamed from src/test/compile-fail/E0308-3.rs)2
-rw-r--r--src/test/compile-fail/bad-main.rs2
-rw-r--r--src/test/compile-fail/extern-main-fn.rs2
-rw-r--r--src/test/compile-fail/main-wrong-type-2.rs2
-rw-r--r--src/test/compile-fail/main-wrong-type.rs2
5 files changed, 5 insertions, 5 deletions
diff --git a/src/test/compile-fail/E0308-3.rs b/src/test/compile-fail/E0580.rs
index d7dca056f3f..a2ef7da78a8 100644
--- a/src/test/compile-fail/E0308-3.rs
+++ b/src/test/compile-fail/E0580.rs
@@ -8,4 +8,4 @@
 // option. This file may not be copied, modified, or distributed
 // except according to those terms.
 
-fn main() -> i32 { 0 } //~ ERROR E0308
+fn main() -> i32 { 0 } //~ ERROR E0580
diff --git a/src/test/compile-fail/bad-main.rs b/src/test/compile-fail/bad-main.rs
index 1253f7569e7..b73b4a6af6e 100644
--- a/src/test/compile-fail/bad-main.rs
+++ b/src/test/compile-fail/bad-main.rs
@@ -8,4 +8,4 @@
 // option. This file may not be copied, modified, or distributed
 // except according to those terms.
 
-fn main(x: isize) { } //~ ERROR: main function has wrong type
+fn main(x: isize) { } //~ ERROR: main function has wrong type [E0580]
diff --git a/src/test/compile-fail/extern-main-fn.rs b/src/test/compile-fail/extern-main-fn.rs
index 11f299acefa..d9bdb4ecd04 100644
--- a/src/test/compile-fail/extern-main-fn.rs
+++ b/src/test/compile-fail/extern-main-fn.rs
@@ -8,4 +8,4 @@
 // option. This file may not be copied, modified, or distributed
 // except according to those terms.
 
-extern fn main() {} //~ ERROR: main function has wrong type
+extern fn main() {} //~ ERROR: main function has wrong type [E0580]
diff --git a/src/test/compile-fail/main-wrong-type-2.rs b/src/test/compile-fail/main-wrong-type-2.rs
index 2878cbc7fc1..9d74d1a9049 100644
--- a/src/test/compile-fail/main-wrong-type-2.rs
+++ b/src/test/compile-fail/main-wrong-type-2.rs
@@ -9,6 +9,6 @@
 // except according to those terms.
 
 fn main() -> char {
-//~^ ERROR: main function has wrong type
+//~^ ERROR: main function has wrong type [E0580]
     ' '
 }
diff --git a/src/test/compile-fail/main-wrong-type.rs b/src/test/compile-fail/main-wrong-type.rs
index 431b855d517..402cd3a2d31 100644
--- a/src/test/compile-fail/main-wrong-type.rs
+++ b/src/test/compile-fail/main-wrong-type.rs
@@ -14,5 +14,5 @@ struct S {
 }
 
 fn main(foo: S) {
-//~^ ERROR: main function has wrong type
+//~^ ERROR: main function has wrong type [E0580]
 }