]> git.lizzy.rs Git - rust.git/blobdiff - src/librustc/diagnostics.rs
diagnostics: Remove main return type errors from E0580
[rust.git] / src / librustc / diagnostics.rs
index b3a904f2f5fec520598714aee8882b5642f33c12..7627071e560373539bf659da6677af1203af7561 100644 (file)
@@ -1764,12 +1764,12 @@ fn main() {
 Erroneous code example:
 
 ```compile_fail,E0580
-fn main() -> i32 { // error: main function has wrong type
-    0
+fn main(x: i32) { // error: main function has wrong type
+    println!("{}", x);
 }
 ```
 
-The `main` function prototype should never take arguments or return type.
+The `main` function prototype should never take arguments.
 Example:
 
 ```