replace if-let and while-let with if let
and while let
This commit is contained in:
parent
ee88f46bb5
commit
0f04875d2e
18 changed files with 45 additions and 45 deletions
|
@ -1,6 +1,6 @@
|
|||
#### Note: this error code is no longer emitted by the compiler.
|
||||
|
||||
An if-let pattern attempts to match the pattern, and enters the body if the
|
||||
An `if let` pattern attempts to match the pattern, and enters the body if the
|
||||
match was successful. If the match is irrefutable (when it cannot fail to
|
||||
match), use a regular `let`-binding instead. For instance:
|
||||
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
#### Note: this error code is no longer emitted by the compiler.
|
||||
|
||||
A while-let pattern attempts to match the pattern, and enters the body if the
|
||||
A `while let` pattern attempts to match the pattern, and enters the body if the
|
||||
match was successful. If the match is irrefutable (when it cannot fail to
|
||||
match), use a regular `let`-binding inside a `loop` instead. For instance:
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue