diff options
| author | Guillaume Gomez <guillaume1.gomez@gmail.com> | 2020-01-02 19:57:25 +0100 |
|---|---|---|
| committer | Guillaume Gomez <guillaume1.gomez@gmail.com> | 2020-01-03 00:07:09 +0100 |
| commit | 8341a9a8f770ad2cf4390446c5da1e590acfc14e (patch) | |
| tree | 1357e240a75ebe42b76bb1bafb81718e450bf498 /src/librustc_error_codes/error_codes | |
| parent | d202b595065b9f20c07d3abc72c47f506f4491f0 (diff) | |
| download | rust-8341a9a8f770ad2cf4390446c5da1e590acfc14e.tar.gz rust-8341a9a8f770ad2cf4390446c5da1e590acfc14e.zip | |
Clean up E0131 error explanation
Diffstat (limited to 'src/librustc_error_codes/error_codes')
| -rw-r--r-- | src/librustc_error_codes/error_codes/E0131.md | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/src/librustc_error_codes/error_codes/E0131.md b/src/librustc_error_codes/error_codes/E0131.md index a70a02925b0..ed798d4f881 100644 --- a/src/librustc_error_codes/error_codes/E0131.md +++ b/src/librustc_error_codes/error_codes/E0131.md @@ -1,8 +1,11 @@ -It is not possible to define `main` with generic parameters. -When `main` is present, it must take no arguments and return `()`. +The `main` function was defined with generic parameters. + Erroneous code example: ```compile_fail,E0131 fn main<T>() { // error: main function is not allowed to have generic parameters } ``` + +It is not possible to define the `main` function with generic parameters. +It must not take any arguments. |
