Skip to content

Commit

Permalink
Rollup merge of rust-lang#72107 - GuillaumeGomez:cleanup-e0579, r=Dyl…
Browse files Browse the repository at this point in the history
…an-DPC

Clean up E0579 explanation

r? @Dylan-DPC
  • Loading branch information
Dylan-DPC authored May 11, 2020
2 parents 46eb9e0 + 806f09c commit ea603f8
Showing 1 changed file with 6 additions and 4 deletions.
10 changes: 6 additions & 4 deletions src/librustc_error_codes/error_codes/E0579.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,4 @@
When matching against an exclusive range, the compiler verifies that the range
is non-empty. Exclusive range patterns include the start point but not the end
point, so this is equivalent to requiring the start of the range to be less
than the end of the range.
A lower range wasn't less than the upper range.

Erroneous code example:

Expand All @@ -17,3 +14,8 @@ fn main() {
}
}
```

When matching against an exclusive range, the compiler verifies that the range
is non-empty. Exclusive range patterns include the start point but not the end
point, so this is equivalent to requiring the start of the range to be less
than the end of the range.

0 comments on commit ea603f8

Please sign in to comment.