Skip to content

Commit

Permalink
Fix linkcheck failures
Browse files Browse the repository at this point in the history
  • Loading branch information
JohnTitor committed Jun 19, 2021
1 parent 1ff9110 commit edd83c5
Show file tree
Hide file tree
Showing 8 changed files with 32 additions and 32 deletions.
38 changes: 19 additions & 19 deletions book.toml
Original file line number Diff line number Diff line change
Expand Up @@ -8,27 +8,27 @@ git-repository-url = "https://github.com/rust-lang/nomicon"

[output.html.redirect]
# Vec-related chapters.
"/vec-alloc.html" = "/vec/vec-alloc.html"
"/vec-dealloc.html" = "/vec/vec-dealloc.html"
"/vec-deref.html" = "/vec/vec-deref.html"
"/vec-drain.html" = "/vec/vec-drain.html"
"/vec-final.html" = "/vec/vec-final.html"
"/vec-insert-remove.html" = "/vec/vec-insert-remove.html"
"/vec-into-iter.html" = "/vec/vec-into-iter.html"
"/vec-layout.html" = "/vec/vec-layout.html"
"/vec-push-pop.html" = "/vec/vec-push-pop.html"
"/vec-raw.html" = "/vec/vec-raw.html"
"/vec-zsts.html" = "/vec/vec-zsts.html"
"/vec.html" = "/vec/vec.html"
"./vec-alloc.html" = "./vec/vec-alloc.html"
"./vec-dealloc.html" = "./vec/vec-dealloc.html"
"./vec-deref.html" = "./vec/vec-deref.html"
"./vec-drain.html" = "./vec/vec-drain.html"
"./vec-final.html" = "./vec/vec-final.html"
"./vec-insert-remove.html" = "./vec/vec-insert-remove.html"
"./vec-into-iter.html" = "./vec/vec-into-iter.html"
"./vec-layout.html" = "./vec/vec-layout.html"
"./vec-push-pop.html" = "./vec/vec-push-pop.html"
"./vec-raw.html" = "./vec/vec-raw.html"
"./vec-zsts.html" = "./vec/vec-zsts.html"
"./vec.html" = "./vec/vec.html"

# Arc and Mutex related chapters.
"/arc-and-mutex.html" = "/arc-mutex/arc-and-mutex.html"
"/arc-base.html" = "/arc-mutex/arc-base.html"
"/arc-clone.html" = "/arc-mutex/arc-clone.html"
"/arc-drop.html" = "/arc-mutex/arc-drop.html"
"/arc-final.html" = "/arc-mutex/arc-final.html"
"/arc-layout.html" = "/arc-mutex/arc-layout.html"
"/arc.html" = "/arc-mutex/arc.html"
"./arc-and-mutex.html" = "./arc-mutex/arc-and-mutex.html"
"./arc-base.html" = "./arc-mutex/arc-base.html"
"./arc-clone.html" = "./arc-mutex/arc-clone.html"
"./arc-drop.html" = "./arc-mutex/arc-drop.html"
"./arc-final.html" = "./arc-mutex/arc-final.html"
"./arc-layout.html" = "./arc-mutex/arc-layout.html"
"./arc.html" = "./arc-mutex/arc.html"

[rust]
edition = "2018"
2 changes: 1 addition & 1 deletion src/arc-mutex/arc-base.md
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ impl<T> Arc<T> {
Since we're building a concurrency primitive, we'll need to be able to send it
across threads. Thus, we can implement the `Send` and `Sync` marker traits. For
more information on these, see [the section on `Send` and
`Sync`](send-and-sync.md).
`Sync`](../send-and-sync.md).

This is okay because:
* You can only get a mutable reference to the value inside an `Arc` if and only
Expand Down
2 changes: 1 addition & 1 deletion src/arc-mutex/arc-clone.md
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ happens-before relationship but is atomic. When `Drop`ping the Arc, however,
we'll need to atomically synchronize when decrementing the reference count. This
is described more in [the section on the `Drop` implementation for
`Arc`](arc-drop.md). For more information on atomic relationships and Relaxed
ordering, see [the section on atomics](atomics.md).
ordering, see [the section on atomics](../atomics.md).

Thus, the code becomes this:

Expand Down
2 changes: 1 addition & 1 deletion src/arc-mutex/arc-layout.md
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ be used where an `Arc<&'a str>` was expected. More importantly, it will give
incorrect ownership information to the drop checker, as it will assume we don't
own any values of type `T`. As this is a structure providing shared ownership of
a value, at some point there will be an instance of this structure that entirely
owns its data. See [the chapter on ownership and lifetimes](ownership.md) for
owns its data. See [the chapter on ownership and lifetimes](../ownership.md) for
all the details on variance and drop check.

To fix the first problem, we can use `NonNull<T>`. Note that `NonNull<T>` is a
Expand Down
2 changes: 1 addition & 1 deletion src/arc-mutex/arc.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# Implementing Arc

In this section, we'll be implementing a simpler version of `std::sync::Arc`.
Similarly to [the implementation of `Vec` we made earlier](vec.md), we won't be
Similarly to [the implementation of `Vec` we made earlier](../vec/vec.md), we won't be
taking advantage of as many optimizations, intrinsics, or unstable code as the
standard library may.

Expand Down
12 changes: 6 additions & 6 deletions src/vec/vec-alloc.md
Original file line number Diff line number Diff line change
Expand Up @@ -202,9 +202,9 @@ impl<T> Vec<T> {
# fn main() {}
```

[Global]: ../std/alloc/struct.Global.html
[handle_alloc_error]: ../alloc/alloc/fn.handle_alloc_error.html
[alloc]: ../alloc/alloc/fn.alloc.html
[realloc]: ../alloc/alloc/fn.realloc.html
[dealloc]: ../alloc/alloc/fn.dealloc.html
[std_alloc]: ../alloc/alloc/index.html
[Global]: ../../std/alloc/struct.Global.html
[handle_alloc_error]: ../../alloc/alloc/fn.handle_alloc_error.html
[alloc]: ../../alloc/alloc/fn.alloc.html
[realloc]: ../../alloc/alloc/fn.realloc.html
[dealloc]: ../../alloc/alloc/fn.dealloc.html
[std_alloc]: ../../alloc/alloc/index.html
2 changes: 1 addition & 1 deletion src/vec/vec-drain.md
Original file line number Diff line number Diff line change
Expand Up @@ -149,4 +149,4 @@ impl<T> Vec<T> {
For more details on the `mem::forget` problem, see the
[section on leaks][leaks].

[leaks]: leaking.html
[leaks]: ../leaking.html
4 changes: 2 additions & 2 deletions src/vec/vec-layout.md
Original file line number Diff line number Diff line change
Expand Up @@ -56,5 +56,5 @@ unsafe impl<T: Sync> Sync for Vec<T> {}
# fn main() {}
```

[ownership]: ownership.html
[NonNull]: ../std/ptr/struct.NonNull.html
[ownership]: ../ownership.html
[NonNull]: ../../std/ptr/struct.NonNull.html

0 comments on commit edd83c5

Please sign in to comment.