Skip to content

Fixing links #989

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Jan 13, 2018
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 1 addition & 2 deletions src/cargo/test.md
Original file line number Diff line number Diff line change
@@ -1,8 +1,7 @@
# Testing

As we know testing is integral to any piece of software! Rust has first-class
support for unit and integration testing ([see that chapter for
more](meta/test.html); or [this
support for unit and integration testing ([see this
chapter](https://doc.rust-lang.org/book/second-edition/ch11-00-testing.html) in
TRPL).

Expand Down
4 changes: 2 additions & 2 deletions src/error/result/enter_question_mark.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ Upon finding an `Err`, there are two valid actions to take:
1. `panic!` which we already decided to try to avoid if possible
2. `return` because an `Err` means it cannot be handled

`?` is *almost*[^1] exactly equivalent to an `unwrap` which `return`s
`?` is *almost*[^] exactly equivalent to an `unwrap` which `return`s
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

So... this one is funky. There are two pages in RBE that are attempting to use the [^1] annotation. The way pulldown-cmark does annotations is by creating a div with id equal to the annotation name (in this case, "1"). This is all well and good, until the print.html page is created, in which case this now results in two different divs with id="1", which is invalid and is a failure to the linkchecker.

I've replaced 1 here with the dagger symbol , which looks like 1 in the fonts used by RBE, but I am not really sure how to address this issue in general since we basically can't use the 1, 2, 3 footnote style for as long as we intend to have a page that concatenates everything together.

instead of `panic`s on `Err`s. Let's see how we can simplify the earlier
example that used combinators:

Expand Down Expand Up @@ -67,6 +67,6 @@ fn main() {
```


[^1]: See [re-enter ?][re_enter_?] for more details.
[^]: See [re-enter ?][re_enter_?] for more details.

[re_enter_?]: error/multiple_error_types/reenter_question_mark.html
4 changes: 2 additions & 2 deletions src/flow_control/match/destructuring/destructure_enum.md
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,6 @@ fn main() {

[`#[allow(...)]`][allow], [color models][color_models] and [`enum`][enum]

[allow]: /attribute/unused.html
[allow]: attribute/unused.html
[color_models]: https://en.wikipedia.org/wiki/Color_model
[enum]: /custom_types/enum.html
[enum]: custom_types/enum.html
Original file line number Diff line number Diff line change
Expand Up @@ -29,4 +29,4 @@ fn main() {

### See also:

[Structs](/custom_types/structs.html), [The ref pattern](/scope/borrow/ref.html)
[Structs](custom_types/structs.html), [The ref pattern](scope/borrow/ref.html)
2 changes: 1 addition & 1 deletion src/flow_control/match/destructuring/destructure_tuple.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,4 +21,4 @@ fn main() {

### See also:

[Tuples](/primitives/tuples.html)
[Tuples](primitives/tuples.html)
10 changes: 7 additions & 3 deletions src/macros/syntax.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,10 @@
In following subsections, we will show how to define macros in Rust.
There are three basic ideas:

- [Patterns and Designators](macros/designators.md)
- [Overloading](macros/overload.md)
- [Repetition](macros/repeat.md)
- [Patterns and Designators][designators]
- [Overloading][overloading]
- [Repetition][repetition]

[designators]: macros/designators.html
[overloading]: macros/overload.html
[repetition]: macros/repeat.html
12 changes: 6 additions & 6 deletions src/std_misc/threads/testcase_mapreduce.md
Original file line number Diff line number Diff line change
Expand Up @@ -140,13 +140,13 @@ defined by a static constant at the beginning of the program.
* [unwrap vs. expect][unwrap]
* [enumerate][enumerate]

[thread]: /std_misc/threads.html
[vectors]: /std/vec.html
[iterators]: /trait/iter.html
[thread]: std_misc/threads.html
[vectors]: std/vec.html
[iterators]: trait/iter.html
[destructuring]: https://doc.rust-lang.org/book/second-edition/ch18-03-pattern-syntax.html#destructuring-to-break-apart-values
[closures]: /fn/closures.html
[move]: /scope/move.html
[closures]: fn/closures.html
[move]: scope/move.html
[move_closure]: https://doc.rust-lang.org/book/second-edition/ch13-01-closures.html#closures-can-capture-their-environment
[turbofish]: https://doc.rust-lang.org/std/iter/trait.Iterator.html#method.collect
[unwrap]: /error/option_unwrap.html
[unwrap]: error/option_unwrap.html
[enumerate]: https://doc.rust-lang.org/book/loops.html#enumerate
2 changes: 1 addition & 1 deletion src/unsafe.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ unsafe blocks are used for:

* dereferencing raw pointers
* calling a function over FFI (but this is covered in [a previous
chapter](/std_misc/ffi.html) of the book)
chapter](std_misc/ffi.html) of the book)
* changing types through `std::mem::transmute`
* inline assembly

Expand Down