Navigation Menu

Skip to content

Commit

Permalink
Add erroneous code example for E0131
Browse files Browse the repository at this point in the history
  • Loading branch information
GuillaumeGomez committed Aug 26, 2015
1 parent af02bcc commit 0c4faf2
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions src/librustc_typeck/diagnostics.rs
Expand Up @@ -1721,6 +1721,12 @@ extern {
E0131: r##"
It is not possible to define `main` with type parameters, or even with function
parameters. When `main` is present, it must take no arguments and return `()`.
Erroneous code example:
```
fn main<T>() { // error: main function is not allowed to have type parameters
}
```
"##,

E0132: r##"
Expand Down

0 comments on commit 0c4faf2

Please sign in to comment.