Skip to content

Commit

Permalink
Fix some typos
Browse files Browse the repository at this point in the history
  • Loading branch information
ykomatsu committed Oct 13, 2015
1 parent ec4362d commit 6ee3134
Showing 1 changed file with 6 additions and 5 deletions.
11 changes: 6 additions & 5 deletions src/doc/trpl/documentation.md
Expand Up @@ -213,7 +213,7 @@ Let's discuss our sample example documentation:
```

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

```rust
Expand All @@ -234,7 +234,7 @@ fn main() {
}
```

Here's the full algorithm rustdoc uses to postprocess examples:
Here's the full algorithm rustdoc uses to preprocess examples:

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

### Running documentation tests

To run the tests, either
To run the tests, either:

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

## `doc` attributes

At a deeper level, documentation comments are sugar for documentation attributes:
At a deeper level, documentation comments are syntactic sugar for documentation
attributes:

```rust
/// this
Expand Down Expand Up @@ -533,7 +534,7 @@ extern crate foo;
pub use foo::bar;
```

This will create documentation for bar both inside the documentation for the
This will create documentation for `bar` both inside the documentation for the
crate `foo`, as well as the documentation for your crate. It will use the same
documentation in both places.

Expand Down

0 comments on commit 6ee3134

Please sign in to comment.