Skip to content

Commit 26911c8

Browse files
committed
Fix plurality of "parentheses"
We had meant to say "parentheses" but had said "parenthesis" in two places. Let's fix that.
1 parent 76cb0ae commit 26911c8

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

text/3617-precise-capturing.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -526,7 +526,7 @@ By not putting the generic parameters on `impl<..>`, we reduce the risk of confu
526526

527527
We put `impl` before `use<..>` because `use<..>` is a property of the opaque type and we're *applying* the generic *parameters* as generic *arguments* to this opaque type. In `impl Trait` syntax, the `impl` keyword is the stand-in for the opaque type itself. Viewed this way, `impl use<..> Trait` maintains the following order, which is seen throughout Rust: *type*, *generic arguments*, *bounds*.
528528

529-
Using angle brackets, rather than parenthesis or square brackets, is consistent with other places in the language where type parameters are applied to a type.
529+
Using angle brackets, rather than parentheses or square brackets, is consistent with other places in the language where type parameters are applied to a type.
530530

531531
At three letters, the `use` keyword is short enough that it doesn't feel too noisy or too much like a burden to use this, and it's parsimonious with other short keywords in Rust.
532532

@@ -602,7 +602,7 @@ We could use the existing `move` keyword, however the word "move" is semanticall
602602

603603
We could use a new short keyword such as `via`. This has the number 1 and 2 drawbacks of `k#captures` mentioned above. As with `move`, it also seems a semantically worse word. With `use<..>`, we can explain that it means the opaque type *uses* the listed generic parameters. In contrast, it's not clear how we could explain the word "via" in this context.
604604

605-
### Using parenthesis or square brackets
605+
### Using parentheses or square brackets
606606

607607
We could say `use('t, T)` or `use['t, T]`. However, in Rust today, generic parameters always fall within angle brackets, even when being applied to a type. Doing something different here could feel inconsistent and doesn't seem warranted.
608608

0 commit comments

Comments
 (0)