diff options
| author | Guillaume Gomez <guillaume1.gomez@gmail.com> | 2020-03-15 14:54:53 +0100 |
|---|---|---|
| committer | Guillaume Gomez <guillaume1.gomez@gmail.com> | 2020-03-19 14:09:54 +0100 |
| commit | 4bf6734f6ffc38745adadd5a8f407630e234685b (patch) | |
| tree | 715a6ee01bbc9cf60def63266b25218ae9cae377 | |
| parent | e5e8ba4edc435c9f87314b23a6c5d9c175bdf19c (diff) | |
| download | rust-4bf6734f6ffc38745adadd5a8f407630e234685b.tar.gz rust-4bf6734f6ffc38745adadd5a8f407630e234685b.zip | |
clean up E0436 explanation
| -rw-r--r-- | src/librustc_error_codes/error_codes/E0436.md | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/src/librustc_error_codes/error_codes/E0436.md b/src/librustc_error_codes/error_codes/E0436.md index b1afd9e9603..48ecc49e92f 100644 --- a/src/librustc_error_codes/error_codes/E0436.md +++ b/src/librustc_error_codes/error_codes/E0436.md @@ -1,5 +1,4 @@ -The functional record update syntax is only allowed for structs. (Struct-like -enum variants don't qualify, for example.) +The functional record update syntax was used on something other than a struct. Erroneous code example: @@ -24,7 +23,9 @@ fn one_up_competitor(competitor_frequency: PublicationFrequency) } ``` -Rewrite the expression without functional record update syntax: +The functional record update syntax is only allowed for structs (struct-like +enum variants don't qualify, for example). To fix the previous code, rewrite the +expression without functional record update syntax: ``` enum PublicationFrequency { |
