Simplify wording in guide for unbraced closures

This commit is contained in:
Josh Triplett 2020-08-28 16:46:07 -07:00
parent 9362ae1616
commit 9ea1180cc7

View File

@ -126,8 +126,8 @@ but elide types where possible.
Use closures without the enclosing `{}`, if possible. Add the `{}` when you have
a return type, when there are statements, when there are comments inside the
closure, or when the body expression spans multiple lines and is a control-flow
expression. If using braces, follow the rules above for blocks. Examples:
closure, or when the body expression is a control-flow expression that spans
multiple lines. If using braces, follow the rules above for blocks. Examples:
```rust
|arg1, arg2| expr