Skip to content

Fix broken anchors in docs #28849

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
Oct 5, 2015
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
2 changes: 1 addition & 1 deletion src/doc/nomicon/lifetime-mismatch.md
Original file line number Diff line number Diff line change
Expand Up @@ -78,4 +78,4 @@ TODO: other common problems? SEME regions stuff, mostly?



[ex2]: lifetimes.html#example-2:-aliasing-a-mutable-reference
[ex2]: lifetimes.html#example-aliasing-a-mutable-reference
2 changes: 1 addition & 1 deletion src/doc/nomicon/repr-rust.md
Original file line number Diff line number Diff line change
Expand Up @@ -151,4 +151,4 @@ use fairly elaborate algorithms to cache bits throughout nested types with
special constrained representations. As such it is *especially* desirable that
we leave enum layout unspecified today.

[dst]: exotic-sizes.html#dynamically-sized-types-(dsts)
[dst]: exotic-sizes.html#dynamically-sized-types-dsts
26 changes: 13 additions & 13 deletions src/doc/reference.md
Original file line number Diff line number Diff line change
Expand Up @@ -1997,7 +1997,7 @@ On `struct`s:
list of names `#[macro_use(foo, bar)]` restricts the import to just those
macros named. The `extern crate` must appear at the crate root, not inside
`mod`, which ensures proper function of the [`$crate` macro
variable](book/macros.html#the-variable-$crate).
variable](book/macros.html#the-variable-crate).

- `macro_reexport` on an `extern crate` — re-export the named macros.

Expand All @@ -2007,7 +2007,7 @@ On `struct`s:
link it into the output.

See the [macros section of the
book](book/macros.html#scoping-and-macro-import/export) for more information on
book](book/macros.html#scoping-and-macro-importexport) for more information on
macro scope.


Expand Down Expand Up @@ -2586,7 +2586,7 @@ Here are some examples:
#### Moved and copied types

When a [local variable](#variables) is used as an
[rvalue](#lvalues,-rvalues-and-temporaries), the variable will be copied
[rvalue](#lvalues-rvalues-and-temporaries), the variable will be copied
if its type implements `Copy`. All others are moved.

### Literal expressions
Expand All @@ -2605,7 +2605,7 @@ value, or the unit value.
### Path expressions

A [path](#paths) used as an expression context denotes either a local variable
or an item. Path expressions are [lvalues](#lvalues,-rvalues-and-temporaries).
or an item. Path expressions are [lvalues](#lvalues-rvalues-and-temporaries).

### Tuple expressions

Expand Down Expand Up @@ -2718,7 +2718,7 @@ foo().x;
(Struct {a: 10, b: 20}).a;
```

A field access is an [lvalue](#lvalues,-rvalues-and-temporaries) referring to
A field access is an [lvalue](#lvalues-rvalues-and-temporaries) referring to
the value of that field. When the type providing the field inherits mutability,
it can be [assigned](#assignment-expressions) to.

Expand All @@ -2729,7 +2729,7 @@ fewer autoderefs to more.

### Array expressions

An [array](#array,-and-slice-types) _expression_ is written by enclosing zero
An [array](#array-and-slice-types) _expression_ is written by enclosing zero
or more comma-separated expressions of uniform type in square brackets.

In the `[expr ';' expr]` form, the expression after the `';'` must be a
Expand All @@ -2745,9 +2745,9 @@ constant expression that can be evaluated at compile time, such as a

### Index expressions

[Array](#array,-and-slice-types)-typed expressions can be indexed by
[Array](#array-and-slice-types)-typed expressions can be indexed by
writing a square-bracket-enclosed expression (the index) after them. When the
array is mutable, the resulting [lvalue](#lvalues,-rvalues-and-temporaries) can
array is mutable, the resulting [lvalue](#lvalues-rvalues-and-temporaries) can
be assigned to.

Indices are zero-based, and may be of any integral type. Vector access is
Expand Down Expand Up @@ -2801,7 +2801,7 @@ before the expression they apply to.
* `*`
: Dereference. When applied to a [pointer](#pointer-types) it denotes the
pointed-to location. For pointers to mutable locations, the resulting
[lvalue](#lvalues,-rvalues-and-temporaries) can be assigned to.
[lvalue](#lvalues-rvalues-and-temporaries) can be assigned to.
On non-pointer types, it calls the `deref` method of the `std::ops::Deref`
trait, or the `deref_mut` method of the `std::ops::DerefMut` trait (if
implemented by the type and required for an outer expression that will or
Expand Down Expand Up @@ -2942,8 +2942,8 @@ surprising side-effects on the dynamic execution semantics.
#### Assignment expressions

An _assignment expression_ consists of an
[lvalue](#lvalues,-rvalues-and-temporaries) expression followed by an equals
sign (`=`) and an [rvalue](#lvalues,-rvalues-and-temporaries) expression.
[lvalue](#lvalues-rvalues-and-temporaries) expression followed by an equals
sign (`=`) and an [rvalue](#lvalues-rvalues-and-temporaries) expression.

Evaluating an assignment expression [either copies or
moves](#moved-and-copied-types) its right-hand operand to its left-hand
Expand Down Expand Up @@ -3170,7 +3170,7 @@ stands for a *single* data field, whereas a wildcard `..` stands for *all* the
fields of a particular variant.

A `match` behaves differently depending on whether or not the head expression
is an [lvalue or an rvalue](#lvalues,-rvalues-and-temporaries). If the head
is an [lvalue or an rvalue](#lvalues-rvalues-and-temporaries). If the head
expression is an rvalue, it is first evaluated into a temporary location, and
the resulting value is sequentially compared to the patterns in the arms until
a match is found. The first arm with a matching pattern is chosen as the branch
Expand Down Expand Up @@ -3489,7 +3489,7 @@ enclosing `enum` or `struct` type itself. Such recursion has restrictions:

* Recursive types must include a nominal type in the recursion
(not mere [type definitions](grammar.html#type-definitions),
or other structural types such as [arrays](#array,-and-slice-types) or [tuples](#tuple-types)).
or other structural types such as [arrays](#array-and-slice-types) or [tuples](#tuple-types)).
* A recursive `enum` item must have at least one non-recursive constructor
(in order to give the recursion a basis case).
* The size of a recursive type must be finite;
Expand Down
2 changes: 1 addition & 1 deletion src/doc/trpl/concurrency.md
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ For sharing references across threads, Rust provides a wrapper type called
`Arc<T>`. `Arc<T>` implements `Send` and `Sync` if and only if `T` implements
both `Send` and `Sync`. For example, an object of type `Arc<RefCell<U>>` cannot
be transferred across threads because
[`RefCell`](choosing-your-guarantees.html#refcell%3Ct%3E) does not implement
[`RefCell`](choosing-your-guarantees.html#refcellt) does not implement
`Sync`, consequently `Arc<RefCell<U>>` would not implement `Send`.

These two traits allow you to use the type system to make strong guarantees
Expand Down
2 changes: 1 addition & 1 deletion src/doc/trpl/conditional-compilation.md
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ These can nest arbitrarily:
As for how to enable or disable these switches, if you’re using Cargo,
they get set in the [`[features]` section][features] of your `Cargo.toml`:

[features]: http://doc.crates.io/manifest.html#the-%5Bfeatures%5D-section
[features]: http://doc.crates.io/manifest.html#the-features-section

```toml
[features]
Expand Down
2 changes: 1 addition & 1 deletion src/doc/trpl/dining-philosophers.md
Original file line number Diff line number Diff line change
Expand Up @@ -434,7 +434,7 @@ ownership of the values it’s capturing. Primarily, the `p` variable of the

Inside the thread, all we do is call `eat()` on `p`. Also note that the call to `thread::spawn` lacks a trailing semicolon, making this an expression. This distinction is important, yielding the correct return value. For more details, read [Expressions vs. Statements][es].

[es]: functions.html#expressions-vs.-statements
[es]: functions.html#expressions-vs-statements

```rust,ignore
}).collect();
Expand Down
4 changes: 2 additions & 2 deletions src/doc/trpl/error-handling.md
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ systems may want to jump around.
* [The `Result` type](#the-result-type)
* [Parsing integers](#parsing-integers)
* [The `Result` type alias idiom](#the-result-type-alias-idiom)
* [A brief interlude: unwrapping isn't evil](#a-brief-interlude-unwrapping-isn't-evil)
* [A brief interlude: unwrapping isn't evil](#a-brief-interlude-unwrapping-isnt-evil)
* [Working with multiple error types](#working-with-multiple-error-types)
* [Composing `Option` and `Result`](#composing-option-and-result)
* [The limits of combinators](#the-limits-of-combinators)
Expand Down Expand Up @@ -1470,7 +1470,7 @@ representation. But certainly, this will vary depending on use cases.
At a minimum, you should probably implement the
[`Error`](../std/error/trait.Error.html)
trait. This will give users of your library some minimum flexibility for
[composing errors](#the-real-try!-macro). Implementing the `Error` trait also
[composing errors](#the-real-try-macro). Implementing the `Error` trait also
means that users are guaranteed the ability to obtain a string representation
of an error (because it requires impls for both `fmt::Debug` and
`fmt::Display`).
Expand Down
2 changes: 1 addition & 1 deletion src/doc/trpl/glossary.md
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ In the example above `x` and `y` have arity 2. `z` has arity 3.

A type without a statically known size or alignment. ([more info][link])

[link]: ../nomicon/exotic-sizes.html#dynamically-sized-types-(dsts)
[link]: ../nomicon/exotic-sizes.html#dynamically-sized-types-dsts

### Expression

Expand Down