Skip to content

Commit 56ab2a1

Browse files
committed
Fix minor typos in doc.rust-lang.org/book
1 parent 0f62d21 commit 56ab2a1

File tree

3 files changed

+4
-4
lines changed

3 files changed

+4
-4
lines changed

src/doc/book/getting-started.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -513,7 +513,7 @@ Cargo checks to see if any of your project’s files have been modified, and onl
513513
rebuilds your project if they’ve changed since the last time you built it.
514514

515515
With simple projects, Cargo doesn't bring a whole lot over just using `rustc`,
516-
but it will become useful in future. This is especially true when you start
516+
but it will become useful in the future. This is especially true when you start
517517
using crates; these are synonymous with a ‘library’ or ‘package’ in other
518518
programming languages. For complex projects composed of multiple crates, it’s
519519
much easier to let Cargo coordinate the build. Using Cargo, you can run `cargo

src/doc/book/if.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ Rust’s take on `if` is not particularly complex, but it’s much more like the
44
`if` you’ll find in a dynamically typed language than in a more traditional
55
systems language. So let’s talk about it, to make sure you grasp the nuances.
66

7-
`if` is a specific form of a more general concept, the ‘branch’. The name comes
7+
`if` is a specific form of a more general concept, the ‘branch’, whose name comes
88
from a branch in a tree: a decision point, where depending on a choice,
99
multiple paths can be taken.
1010

src/doc/book/strings.md

+2-2
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@ let s = "foo\
4444
assert_eq!("foobar", s);
4545
```
4646

47-
Rust has more than only `&str`s though. A `String`, is a heap-allocated string.
47+
Rust has more than only `&str`s though. A `String` is a heap-allocated string.
4848
This string is growable, and is also guaranteed to be UTF-8. `String`s are
4949
commonly created by converting from a string slice using the `to_string`
5050
method.
@@ -89,7 +89,7 @@ Viewing a `String` as a `&str` is cheap, but converting the `&str` to a
8989

9090
## Indexing
9191

92-
Because strings are valid UTF-8, strings do not support indexing:
92+
Because strings are valid UTF-8, they do not support indexing:
9393

9494
```rust,ignore
9595
let s = "hello";

0 commit comments

Comments
 (0)