Skip to content

Commit

Permalink
Rollup merge of rust-lang#38662 - agl:patch-2, r=frewsxcv
Browse files Browse the repository at this point in the history
Use "an" before "i32"

(Minor typo fix.)

Since the word `i32` starts with a vowel, the indefinite article should use "an", not "a" \[[1](http://www.dictionary.com/browse/an)\]. (Previously there was one instance of "an i32" and two instances of "a i32", so at least something is wrong!) Since I believe that "an" is the correct form, I aligned everything with that.
  • Loading branch information
alexcrichton authored Dec 30, 2016
2 parents 3f65c5d + 57b53fd commit 2068e1c
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/doc/book/closures.md
Original file line number Diff line number Diff line change
Expand Up @@ -283,7 +283,7 @@ fn call_with_one<F>(some_closure: F) -> i32
# some_closure(1) }
```

We take one parameter, and it has the type `F`. We also return a `i32`. This part
We take one parameter, and it has the type `F`. We also return an `i32`. This part
isn’t interesting. The next part is:

```rust
Expand All @@ -293,7 +293,7 @@ isn’t interesting. The next part is:
```

Because `Fn` is a trait, we can use it as a bound for our generic type. In
this case, our closure takes a `i32` as an argument and returns an `i32`, and
this case, our closure takes an `i32` as an argument and returns an `i32`, and
so the generic bound we use is `Fn(i32) -> i32`.

There’s one other key point here: because we’re bounding a generic with a
Expand Down

0 comments on commit 2068e1c

Please sign in to comment.