Skip to content

Commit 6ee3134

Browse files
committed
Fix some typos
1 parent ec4362d commit 6ee3134

File tree

1 file changed

+6
-5
lines changed

1 file changed

+6
-5
lines changed

src/doc/trpl/documentation.md

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -213,7 +213,7 @@ Let's discuss our sample example documentation:
213213
```
214214

215215
You'll notice that you don't need a `fn main()` or anything here. `rustdoc` will
216-
automatically add a main() wrapper around your code, and in the right place.
216+
automatically add a `main()` wrapper around your code, and in the right place.
217217
For example:
218218

219219
```rust
@@ -234,7 +234,7 @@ fn main() {
234234
}
235235
```
236236

237-
Here's the full algorithm rustdoc uses to postprocess examples:
237+
Here's the full algorithm rustdoc uses to preprocess examples:
238238

239239
1. Any leading `#![foo]` attributes are left intact as crate attributes.
240240
2. Some common `allow` attributes are inserted, including
@@ -377,7 +377,7 @@ things, so they don’t show up in the output.
377377

378378
### Running documentation tests
379379

380-
To run the tests, either
380+
To run the tests, either:
381381

382382
```bash
383383
$ rustdoc --test path/to/my/crate/root.rs
@@ -502,7 +502,8 @@ This `%` line needs to be the very first line of the file.
502502

503503
## `doc` attributes
504504

505-
At a deeper level, documentation comments are sugar for documentation attributes:
505+
At a deeper level, documentation comments are syntactic sugar for documentation
506+
attributes:
506507

507508
```rust
508509
/// this
@@ -533,7 +534,7 @@ extern crate foo;
533534
pub use foo::bar;
534535
```
535536

536-
This will create documentation for bar both inside the documentation for the
537+
This will create documentation for `bar` both inside the documentation for the
537538
crate `foo`, as well as the documentation for your crate. It will use the same
538539
documentation in both places.
539540

0 commit comments

Comments
 (0)