1
Fork 0

doc: Fix a bunch of broken links

A few categories:

* Links into compiler docs were just all removed as we're not generating
  compiler docs.
* Move up one more level to forcibly go to std docs to fix inlined documentation
  across the facade crates.
This commit is contained in:
Alex Crichton 2016-03-07 23:55:52 -08:00
parent 16fefc5ead
commit 73db76015e
23 changed files with 132 additions and 136 deletions

View file

@ -204,7 +204,7 @@ borrow checker. Generally we know that such mutations won't happen in a nested f
to check. to check.
For large, complicated programs, it becomes useful to put some things in `RefCell`s to make things For large, complicated programs, it becomes useful to put some things in `RefCell`s to make things
simpler. For example, a lot of the maps in [the `ctxt` struct][ctxt] in the Rust compiler internals simpler. For example, a lot of the maps in the `ctxt` struct in the Rust compiler internals
are inside this wrapper. These are only modified once (during creation, which is not right after are inside this wrapper. These are only modified once (during creation, which is not right after
initialization) or a couple of times in well-separated places. However, since this struct is initialization) or a couple of times in well-separated places. However, since this struct is
pervasively used everywhere, juggling mutable and immutable pointers would be hard (perhaps pervasively used everywhere, juggling mutable and immutable pointers would be hard (perhaps
@ -235,7 +235,6 @@ At runtime each borrow causes a modification/check of the refcount.
[cell-mod]: ../std/cell/ [cell-mod]: ../std/cell/
[cell]: ../std/cell/struct.Cell.html [cell]: ../std/cell/struct.Cell.html
[refcell]: ../std/cell/struct.RefCell.html [refcell]: ../std/cell/struct.RefCell.html
[ctxt]: ../rustc/middle/ty/struct.ctxt.html
# Synchronous types # Synchronous types

View file

@ -8,12 +8,12 @@ extend the compiler's behavior with new syntax extensions, lint checks, etc.
A plugin is a dynamic library crate with a designated *registrar* function that A plugin is a dynamic library crate with a designated *registrar* function that
registers extensions with `rustc`. Other crates can load these extensions using registers extensions with `rustc`. Other crates can load these extensions using
the crate attribute `#![plugin(...)]`. See the the crate attribute `#![plugin(...)]`. See the
[`rustc_plugin`](../rustc_plugin/index.html) documentation for more about the `rustc_plugin` documentation for more about the
mechanics of defining and loading a plugin. mechanics of defining and loading a plugin.
If present, arguments passed as `#![plugin(foo(... args ...))]` are not If present, arguments passed as `#![plugin(foo(... args ...))]` are not
interpreted by rustc itself. They are provided to the plugin through the interpreted by rustc itself. They are provided to the plugin through the
`Registry`'s [`args` method](../rustc_plugin/registry/struct.Registry.html#method.args). `Registry`'s `args` method.
In the vast majority of cases, a plugin should *only* be used through In the vast majority of cases, a plugin should *only* be used through
`#![plugin]` and not through an `extern crate` item. Linking a plugin would `#![plugin]` and not through an `extern crate` item. Linking a plugin would
@ -30,7 +30,7 @@ of a library.
Plugins can extend Rust's syntax in various ways. One kind of syntax extension Plugins can extend Rust's syntax in various ways. One kind of syntax extension
is the procedural macro. These are invoked the same way as [ordinary is the procedural macro. These are invoked the same way as [ordinary
macros](macros.html), but the expansion is performed by arbitrary Rust macros](macros.html), but the expansion is performed by arbitrary Rust
code that manipulates [syntax trees](../syntax/ast/index.html) at code that manipulates syntax trees at
compile time. compile time.
Let's write a plugin Let's write a plugin
@ -120,11 +120,8 @@ The advantages over a simple `fn(&str) -> u32` are:
In addition to procedural macros, you can define new In addition to procedural macros, you can define new
[`derive`](../reference.html#derive)-like attributes and other kinds of [`derive`](../reference.html#derive)-like attributes and other kinds of
extensions. See extensions. See `Registry::register_syntax_extension` and the `SyntaxExtension`
[`Registry::register_syntax_extension`](../rustc_plugin/registry/struct.Registry.html#method.register_syntax_extension) enum. For a more involved macro example, see
and the [`SyntaxExtension`
enum](https://doc.rust-lang.org/syntax/ext/base/enum.SyntaxExtension.html). For
a more involved macro example, see
[`regex_macros`](https://github.com/rust-lang/regex/blob/master/regex_macros/src/lib.rs). [`regex_macros`](https://github.com/rust-lang/regex/blob/master/regex_macros/src/lib.rs).
@ -132,7 +129,7 @@ a more involved macro example, see
Some of the [macro debugging tips](macros.html#debugging-macro-code) are applicable. Some of the [macro debugging tips](macros.html#debugging-macro-code) are applicable.
You can use [`syntax::parse`](../syntax/parse/index.html) to turn token trees into You can use `syntax::parse` to turn token trees into
higher-level syntax elements like expressions: higher-level syntax elements like expressions:
```ignore ```ignore
@ -148,30 +145,21 @@ Looking through [`libsyntax` parser
code](https://github.com/rust-lang/rust/blob/master/src/libsyntax/parse/parser.rs) code](https://github.com/rust-lang/rust/blob/master/src/libsyntax/parse/parser.rs)
will give you a feel for how the parsing infrastructure works. will give you a feel for how the parsing infrastructure works.
Keep the [`Span`s](../syntax/codemap/struct.Span.html) of Keep the `Span`s of everything you parse, for better error reporting. You can
everything you parse, for better error reporting. You can wrap wrap `Spanned` around your custom data structures.
[`Spanned`](../syntax/codemap/struct.Spanned.html) around
your custom data structures.
Calling Calling `ExtCtxt::span_fatal` will immediately abort compilation. It's better to
[`ExtCtxt::span_fatal`](../syntax/ext/base/struct.ExtCtxt.html#method.span_fatal) instead call `ExtCtxt::span_err` and return `DummyResult` so that the compiler
will immediately abort compilation. It's better to instead call can continue and find further errors.
[`ExtCtxt::span_err`](../syntax/ext/base/struct.ExtCtxt.html#method.span_err)
and return
[`DummyResult`](../syntax/ext/base/struct.DummyResult.html),
so that the compiler can continue and find further errors.
To print syntax fragments for debugging, you can use To print syntax fragments for debugging, you can use `span_note` together with
[`span_note`](../syntax/ext/base/struct.ExtCtxt.html#method.span_note) together `syntax::print::pprust::*_to_string`.
with
[`syntax::print::pprust::*_to_string`](https://doc.rust-lang.org/syntax/print/pprust/index.html#functions).
The example above produced an integer literal using The example above produced an integer literal using `AstBuilder::expr_usize`.
[`AstBuilder::expr_usize`](../syntax/ext/build/trait.AstBuilder.html#tymethod.expr_usize).
As an alternative to the `AstBuilder` trait, `libsyntax` provides a set of As an alternative to the `AstBuilder` trait, `libsyntax` provides a set of
[quasiquote macros](../syntax/ext/quote/index.html). They are undocumented and quasiquote macros. They are undocumented and very rough around the edges.
very rough around the edges. However, the implementation may be a good However, the implementation may be a good starting point for an improved
starting point for an improved quasiquote as an ordinary plugin library. quasiquote as an ordinary plugin library.
# Lint plugins # Lint plugins
@ -239,12 +227,11 @@ foo.rs:4 fn lintme() { }
The components of a lint plugin are: The components of a lint plugin are:
* one or more `declare_lint!` invocations, which define static * one or more `declare_lint!` invocations, which define static `Lint` structs;
[`Lint`](../rustc/lint/struct.Lint.html) structs;
* a struct holding any state needed by the lint pass (here, none); * a struct holding any state needed by the lint pass (here, none);
* a [`LintPass`](../rustc/lint/trait.LintPass.html) * a `LintPass`
implementation defining how to check each syntax element. A single implementation defining how to check each syntax element. A single
`LintPass` may call `span_lint` for several different `Lint`s, but should `LintPass` may call `span_lint` for several different `Lint`s, but should
register them all through the `get_lints` method. register them all through the `get_lints` method.

View file

@ -1,4 +1,4 @@
% The (old) Rust Compiler Plugins Guide % The (old) Rust Compiler Plugins Guide
This content has moved into This content has moved into
[the Rust Programming Language book](book/plugins.html). [the Rust Programming Language book](book/compiler-plugins.html).

View file

@ -53,7 +53,7 @@ This document is broken into four parts:
cross-cutting topic, starting with cross-cutting topic, starting with
[Ownership and resources](ownership/README.md). [Ownership and resources](ownership/README.md).
* **[APIs for a changing Rust](changing/README.md)** * **APIs for a changing Rust**
discusses the forward-compatibility hazards, especially those that interact discusses the forward-compatibility hazards, especially those that interact
with the pre-1.0 library stabilization process. with the pre-1.0 library stabilization process.

View file

@ -76,7 +76,7 @@ needs to make about its arguments.
On the other hand, generics can make it more difficult to read and understand a On the other hand, generics can make it more difficult to read and understand a
function's signature. Aim for "natural" parameter types that a neither overly function's signature. Aim for "natural" parameter types that a neither overly
concrete nor overly abstract. See the discussion on concrete nor overly abstract. See the discussion on
[traits](../../traits/README.md) for more guidance. [traits](../traits/README.md) for more guidance.
#### Minimizing ownership assumptions: #### Minimizing ownership assumptions:

View file

@ -101,7 +101,7 @@ The convention for a field `foo: T` is:
here may take `&T` or some other type, depending on the context.) here may take `&T` or some other type, depending on the context.)
Note that this convention is about getters/setters on ordinary data types, *not* Note that this convention is about getters/setters on ordinary data types, *not*
on [builder objects](../ownership/builders.html). on [builder objects](../../ownership/builders.html).
### Escape hatches [FIXME] ### Escape hatches [FIXME]

View file

@ -34,8 +34,8 @@ use Bound;
/// to any other item, as determined by the [`Ord`] trait, changes while it is in the set. This is /// to any other item, as determined by the [`Ord`] trait, changes while it is in the set. This is
/// normally only possible through [`Cell`], [`RefCell`], global state, I/O, or unsafe code. /// normally only possible through [`Cell`], [`RefCell`], global state, I/O, or unsafe code.
/// ///
/// [`BTreeMap`]: ../struct.BTreeMap.html /// [`BTreeMap`]: struct.BTreeMap.html
/// [`Ord`]: ../../core/cmp/trait.Ord.html /// [`Ord`]: ../../std/cmp/trait.Ord.html
/// [`Cell`]: ../../std/cell/struct.Cell.html /// [`Cell`]: ../../std/cell/struct.Cell.html
/// [`RefCell`]: ../../std/cell/struct.RefCell.html /// [`RefCell`]: ../../std/cell/struct.RefCell.html
#[derive(Clone, Hash, PartialEq, Eq, Ord, PartialOrd)] #[derive(Clone, Hash, PartialEq, Eq, Ord, PartialOrd)]

View file

@ -71,13 +71,21 @@ extern crate std;
#[cfg(test)] #[cfg(test)]
extern crate test; extern crate test;
#[doc(no_inline)]
pub use binary_heap::BinaryHeap; pub use binary_heap::BinaryHeap;
#[doc(no_inline)]
pub use btree_map::BTreeMap; pub use btree_map::BTreeMap;
#[doc(no_inline)]
pub use btree_set::BTreeSet; pub use btree_set::BTreeSet;
#[doc(no_inline)]
pub use linked_list::LinkedList; pub use linked_list::LinkedList;
#[doc(no_inline)]
pub use enum_set::EnumSet; pub use enum_set::EnumSet;
#[doc(no_inline)]
pub use vec_deque::VecDeque; pub use vec_deque::VecDeque;
#[doc(no_inline)]
pub use string::String; pub use string::String;
#[doc(no_inline)]
pub use vec::Vec; pub use vec::Vec;
// Needed for the vec! macro // Needed for the vec! macro

View file

@ -78,7 +78,7 @@
//! * Further methods that return iterators are `.split()`, `.splitn()`, //! * Further methods that return iterators are `.split()`, `.splitn()`,
//! `.chunks()`, `.windows()` and more. //! `.chunks()`, `.windows()` and more.
//! //!
//! *[See also the slice primitive type](../primitive.slice.html).* //! *[See also the slice primitive type](../../std/primitive.slice.html).*
#![stable(feature = "rust1", since = "1.0.0")] #![stable(feature = "rust1", since = "1.0.0")]
// Many of the usings in this module are only used in the test configuration. // Many of the usings in this module are only used in the test configuration.

View file

@ -10,7 +10,7 @@
//! Unicode string slices. //! Unicode string slices.
//! //!
//! *[See also the `str` primitive type](../primitive.str.html).* //! *[See also the `str` primitive type](../../std/primitive.str.html).*
#![stable(feature = "rust1", since = "1.0.0")] #![stable(feature = "rust1", since = "1.0.0")]

View file

@ -79,7 +79,7 @@ use boxed::Box;
/// contents of the string. It has a close relationship with its borrowed /// contents of the string. It has a close relationship with its borrowed
/// counterpart, the primitive [`str`]. /// counterpart, the primitive [`str`].
/// ///
/// [`str`]: ../primitive.str.html /// [`str`]: ../../std/primitive.str.html
/// ///
/// # Examples /// # Examples
/// ///
@ -99,7 +99,7 @@ use boxed::Box;
/// hello.push_str("orld!"); /// hello.push_str("orld!");
/// ``` /// ```
/// ///
/// [`char`]: ../primitive.char.html /// [`char`]: ../../std/primitive.char.html
/// [`push()`]: #method.push /// [`push()`]: #method.push
/// [`push_str()`]: #method.push_str /// [`push_str()`]: #method.push_str
/// ///
@ -131,7 +131,7 @@ use boxed::Box;
/// println!("The first letter of s is {}", s[0]); // ERROR!!! /// println!("The first letter of s is {}", s[0]); // ERROR!!!
/// ``` /// ```
/// ///
/// [`OsString`]: ../ffi/struct.OsString.html /// [`OsString`]: ../../std/ffi/struct.OsString.html
/// ///
/// Indexing is intended to be a constant-time operation, but UTF-8 encoding /// Indexing is intended to be a constant-time operation, but UTF-8 encoding
/// does not allow us to do this. Furtheremore, it's not clear what sort of /// does not allow us to do this. Furtheremore, it's not clear what sort of
@ -156,8 +156,8 @@ use boxed::Box;
/// takes_str(&s); /// takes_str(&s);
/// ``` /// ```
/// ///
/// [`&str`]: ../primitive.str.html /// [`&str`]: ../../std/primitive.str.html
/// [`Deref`]: ../ops/trait.Deref.html /// [`Deref`]: ../../std/ops/trait.Deref.html
/// ///
/// This will create a [`&str`] from the `String` and pass it in. This /// This will create a [`&str`] from the `String` and pass it in. This
/// conversion is very inexpensive, and so generally, functions will accept /// conversion is very inexpensive, and so generally, functions will accept
@ -280,10 +280,10 @@ pub struct String {
/// an analogue to `FromUtf8Error`, and you can get one from a `FromUtf8Error` /// an analogue to `FromUtf8Error`, and you can get one from a `FromUtf8Error`
/// through the [`utf8_error()`] method. /// through the [`utf8_error()`] method.
/// ///
/// [`Utf8Error`]: ../str/struct.Utf8Error.html /// [`Utf8Error`]: ../../std/str/struct.Utf8Error.html
/// [`std::str`]: ../str/index.html /// [`std::str`]: ../../std/str/index.html
/// [`u8`]: ../primitive.u8.html /// [`u8`]: ../../std/primitive.u8.html
/// [`&str`]: ../primitive.str.html /// [`&str`]: ../../std/primitive.str.html
/// [`utf8_error()`]: #method.utf8_error /// [`utf8_error()`]: #method.utf8_error
/// ///
/// # Examples /// # Examples
@ -414,9 +414,9 @@ impl String {
/// requires that it is valid UTF-8. `from_utf8()` checks to ensure that /// requires that it is valid UTF-8. `from_utf8()` checks to ensure that
/// the bytes are valid UTF-8, and then does the conversion. /// the bytes are valid UTF-8, and then does the conversion.
/// ///
/// [`&str`]: ../primitive.str.html /// [`&str`]: ../../std/primitive.str.html
/// [`u8`]: ../primitive.u8.html /// [`u8`]: ../../std/primitive.u8.html
/// [`Vec<u8>`]: ../vec/struct.Vec.html /// [`Vec<u8>`]: ../../std/vec/struct.Vec.html
/// ///
/// If you are sure that the byte slice is valid UTF-8, and you don't want /// If you are sure that the byte slice is valid UTF-8, and you don't want
/// to incur the overhead of the validity check, there is an unsafe version /// to incur the overhead of the validity check, there is an unsafe version
@ -431,7 +431,7 @@ impl String {
/// If you need a `&str` instead of a `String`, consider /// If you need a `&str` instead of a `String`, consider
/// [`str::from_utf8()`]. /// [`str::from_utf8()`].
/// ///
/// [`str::from_utf8()`]: ../str/fn.from_utf8.html /// [`str::from_utf8()`]: ../../std/str/fn.from_utf8.html
/// ///
/// # Errors /// # Errors
/// ///
@ -488,8 +488,8 @@ impl String {
/// `from_utf8_lossy()` will replace any invalid UTF-8 sequences with /// `from_utf8_lossy()` will replace any invalid UTF-8 sequences with
/// `U+FFFD REPLACEMENT CHARACTER`, which looks like this: <20> /// `U+FFFD REPLACEMENT CHARACTER`, which looks like this: <20>
/// ///
/// [`u8`]: ../primitive.u8.html /// [`u8`]: ../../std/primitive.u8.html
/// [byteslice]: ../primitive.slice.html /// [byteslice]: ../../std/primitive.slice.html
/// ///
/// If you are sure that the byte slice is valid UTF-8, and you don't want /// If you are sure that the byte slice is valid UTF-8, and you don't want
/// to incur the overhead of the conversion, there is an unsafe version /// to incur the overhead of the conversion, there is an unsafe version
@ -504,7 +504,7 @@ impl String {
/// it's already valid UTF-8, we don't need a new allocation. This return /// it's already valid UTF-8, we don't need a new allocation. This return
/// type allows us to handle both cases. /// type allows us to handle both cases.
/// ///
/// [`Cow<'a, str>`]: ../borrow/enum.Cow.html /// [`Cow<'a, str>`]: ../../std/borrow/enum.Cow.html
/// ///
/// # Examples /// # Examples
/// ///
@ -1014,7 +1014,7 @@ impl String {
/// Panics if `new_len` > current length, or if `new_len` does not lie on a /// Panics if `new_len` > current length, or if `new_len` does not lie on a
/// [`char`] boundary. /// [`char`] boundary.
/// ///
/// [`char`]: ../primitive.char.html /// [`char`]: ../../std/primitive.char.html
/// ///
/// # Examples /// # Examples
/// ///
@ -1076,7 +1076,7 @@ impl String {
/// Panics if `idx` is larger than or equal to the `String`'s length, /// Panics if `idx` is larger than or equal to the `String`'s length,
/// or if it does not lie on a [`char`] boundary. /// or if it does not lie on a [`char`] boundary.
/// ///
/// [`char`]: ../primitive.char.html /// [`char`]: ../../std/primitive.char.html
/// ///
/// # Examples /// # Examples
/// ///
@ -1116,7 +1116,7 @@ impl String {
/// Panics if `idx` is larger than the `String`'s length, or if it does not /// Panics if `idx` is larger than the `String`'s length, or if it does not
/// lie on a [`char`] boundary. /// lie on a [`char`] boundary.
/// ///
/// [`char`]: ../primitive.char.html /// [`char`]: ../../std/primitive.char.html
/// ///
/// # Examples /// # Examples
/// ///
@ -1255,7 +1255,7 @@ impl String {
/// Panics if the starting point or end point do not lie on a [`char`] /// Panics if the starting point or end point do not lie on a [`char`]
/// boundary, or if they're out of bounds. /// boundary, or if they're out of bounds.
/// ///
/// [`char`]: ../primitive.char.html /// [`char`]: ../../std/primitive.char.html
/// ///
/// # Examples /// # Examples
/// ///
@ -1353,10 +1353,10 @@ impl FromUtf8Error {
/// an analogue to `FromUtf8Error`. See its documentation for more details /// an analogue to `FromUtf8Error`. See its documentation for more details
/// on using it. /// on using it.
/// ///
/// [`Utf8Error`]: ../str/struct.Utf8Error.html /// [`Utf8Error`]: ../../std/str/struct.Utf8Error.html
/// [`std::str`]: ../str/index.html /// [`std::str`]: ../../std/str/index.html
/// [`u8`]: ../primitive.u8.html /// [`u8`]: ../../std/primitive.u8.html
/// [`&str`]: ../primitive.str.html /// [`&str`]: ../../std/primitive.str.html
/// ///
/// # Examples /// # Examples
/// ///
@ -1695,9 +1695,9 @@ impl ops::DerefMut for String {
/// [`String`] without error, this type will never actually be returned. As /// [`String`] without error, this type will never actually be returned. As
/// such, it is only here to satisfy said signature, and is useless otherwise. /// such, it is only here to satisfy said signature, and is useless otherwise.
/// ///
/// [`FromStr`]: ../str/trait.FromStr.html /// [`FromStr`]: ../../std/str/trait.FromStr.html
/// [`String`]: struct.String.html /// [`String`]: struct.String.html
/// [`from_str()`]: ../str/trait.FromStr.html#tymethod.from_str /// [`from_str()`]: ../../std/str/trait.FromStr.html#tymethod.from_str
#[stable(feature = "str_parse_error", since = "1.5.0")] #[stable(feature = "str_parse_error", since = "1.5.0")]
#[derive(Copy)] #[derive(Copy)]
pub enum ParseError {} pub enum ParseError {}
@ -1749,7 +1749,7 @@ impl Eq for ParseError {}
/// [`Display`] should be implemented instead, and you get the `ToString` /// [`Display`] should be implemented instead, and you get the `ToString`
/// implementation for free. /// implementation for free.
/// ///
/// [`Display`]: ../fmt/trait.Display.html /// [`Display`]: ../../std/fmt/trait.Display.html
#[stable(feature = "rust1", since = "1.0.0")] #[stable(feature = "rust1", since = "1.0.0")]
pub trait ToString { pub trait ToString {
/// Converts the given value to a `String`. /// Converts the given value to a `String`.

View file

@ -22,7 +22,7 @@
//! Note that &Any is limited to testing whether a value is of a specified //! Note that &Any is limited to testing whether a value is of a specified
//! concrete type, and cannot be used to test whether a type implements a trait. //! concrete type, and cannot be used to test whether a type implements a trait.
//! //!
//! [`Box`]: ../boxed/struct.Box.html //! [`Box`]: ../../std/boxed/struct.Box.html
//! //!
//! # Examples //! # Examples
//! //!

View file

@ -69,7 +69,7 @@ const MAX_THREE_B: u32 = 0x10000;
/// Point], but only ones within a certain range. `MAX` is the highest valid /// Point], but only ones within a certain range. `MAX` is the highest valid
/// code point that's a valid [Unicode Scalar Value]. /// code point that's a valid [Unicode Scalar Value].
/// ///
/// [`char`]: ../primitive.char.html /// [`char`]: ../../std/primitive.char.html
/// [Unicode Scalar Value]: http://www.unicode.org/glossary/#unicode_scalar_value /// [Unicode Scalar Value]: http://www.unicode.org/glossary/#unicode_scalar_value
/// [Code Point]: http://www.unicode.org/glossary/#code_point /// [Code Point]: http://www.unicode.org/glossary/#code_point
#[stable(feature = "rust1", since = "1.0.0")] #[stable(feature = "rust1", since = "1.0.0")]
@ -91,8 +91,8 @@ pub const MAX: char = '\u{10ffff}';
/// [`char`]s. `from_u32()` will return `None` if the input is not a valid value /// [`char`]s. `from_u32()` will return `None` if the input is not a valid value
/// for a [`char`]. /// for a [`char`].
/// ///
/// [`char`]: ../primitive.char.html /// [`char`]: ../../std/primitive.char.html
/// [`u32`]: ../primitive.u32.html /// [`u32`]: ../../std/primitive.u32.html
/// [`as`]: ../../book/casting-between-types.html#as /// [`as`]: ../../book/casting-between-types.html#as
/// ///
/// For an unsafe version of this function which ignores these checks, see /// For an unsafe version of this function which ignores these checks, see
@ -148,8 +148,8 @@ pub fn from_u32(i: u32) -> Option<char> {
/// [`char`]s. `from_u32_unchecked()` will ignore this, and blindly cast to /// [`char`]s. `from_u32_unchecked()` will ignore this, and blindly cast to
/// [`char`], possibly creating an invalid one. /// [`char`], possibly creating an invalid one.
/// ///
/// [`char`]: ../primitive.char.html /// [`char`]: ../../std/primitive.char.html
/// [`u32`]: ../primitive.u32.html /// [`u32`]: ../../std/primitive.u32.html
/// [`as`]: ../../book/casting-between-types.html#as /// [`as`]: ../../book/casting-between-types.html#as
/// ///
/// # Safety /// # Safety
@ -414,8 +414,8 @@ pub fn encode_utf16_raw(mut ch: u32, dst: &mut [u16]) -> Option<usize> {
/// This `struct` is created by the [`escape_unicode()`] method on [`char`]. See /// This `struct` is created by the [`escape_unicode()`] method on [`char`]. See
/// its documentation for more. /// its documentation for more.
/// ///
/// [`escape_unicode()`]: ../primitive.char.html#method.escape_unicode /// [`escape_unicode()`]: ../../std/primitive.char.html#method.escape_unicode
/// [`char`]: ../primitive.char.html /// [`char`]: ../../std/primitive.char.html
#[derive(Clone)] #[derive(Clone)]
#[stable(feature = "rust1", since = "1.0.0")] #[stable(feature = "rust1", since = "1.0.0")]
pub struct EscapeUnicode { pub struct EscapeUnicode {
@ -494,8 +494,8 @@ impl Iterator for EscapeUnicode {
/// This `struct` is created by the [`escape_default()`] method on [`char`]. See /// This `struct` is created by the [`escape_default()`] method on [`char`]. See
/// its documentation for more. /// its documentation for more.
/// ///
/// [`escape_default()`]: ../primitive.char.html#method.escape_default /// [`escape_default()`]: ../../std/primitive.char.html#method.escape_default
/// [`char`]: ../primitive.char.html /// [`char`]: ../../std/primitive.char.html
#[derive(Clone)] #[derive(Clone)]
#[stable(feature = "rust1", since = "1.0.0")] #[stable(feature = "rust1", since = "1.0.0")]
pub struct EscapeDefault { pub struct EscapeDefault {

View file

@ -65,7 +65,7 @@
//! //!
//! [`Iterator`]: trait.Iterator.html //! [`Iterator`]: trait.Iterator.html
//! [`next()`]: trait.Iterator.html#tymethod.next //! [`next()`]: trait.Iterator.html#tymethod.next
//! [`Option`]: ../option/enum.Option.html //! [`Option`]: ../../std/option/enum.Option.html
//! //!
//! # The three forms of iteration //! # The three forms of iteration
//! //!
@ -804,7 +804,7 @@ pub trait Iterator {
/// closure returns `None`, it will try again, and call the closure on the /// closure returns `None`, it will try again, and call the closure on the
/// next element, seeing if it will return `Some`. /// next element, seeing if it will return `Some`.
/// ///
/// [`Option<T>`]: ../option/enum.Option.html /// [`Option<T>`]: ../../std/option/enum.Option.html
/// ///
/// Why `filter_map()` and not just [`filter()`].[`map()`]? The key is in this /// Why `filter_map()` and not just [`filter()`].[`map()`]? The key is in this
/// part: /// part:
@ -866,7 +866,7 @@ pub trait Iterator {
/// different sized integer, the [`zip()`] function provides similar /// different sized integer, the [`zip()`] function provides similar
/// functionality. /// functionality.
/// ///
/// [`usize`]: ../primitive.usize.html /// [`usize`]: ../../std/primitive.usize.html
/// [`zip()`]: #method.zip /// [`zip()`]: #method.zip
/// ///
/// # Overflow Behavior /// # Overflow Behavior
@ -875,7 +875,7 @@ pub trait Iterator {
/// [`usize::MAX`] elements either produces the wrong result or panics. If /// [`usize::MAX`] elements either produces the wrong result or panics. If
/// debug assertions are enabled, a panic is guaranteed. /// debug assertions are enabled, a panic is guaranteed.
/// ///
/// [`usize::MAX`]: ../usize/constant.MAX.html /// [`usize::MAX`]: ../../std/usize/constant.MAX.html
/// ///
/// # Panics /// # Panics
/// ///
@ -1151,7 +1151,7 @@ pub trait Iterator {
/// iterator and the return value from the closure, an [`Option`], is /// iterator and the return value from the closure, an [`Option`], is
/// yielded by the iterator. /// yielded by the iterator.
/// ///
/// [`Option`]: ../option/enum.Option.html /// [`Option`]: ../../std/option/enum.Option.html
/// ///
/// # Examples /// # Examples
/// ///
@ -1385,9 +1385,9 @@ pub trait Iterator {
/// be thought of as single `Result<Collection<T>, E>`. See the examples /// be thought of as single `Result<Collection<T>, E>`. See the examples
/// below for more. /// below for more.
/// ///
/// [`String`]: ../string/struct.String.html /// [`String`]: ../../std/string/struct.String.html
/// [`Result<T, E>`]: ../result/enum.Result.html /// [`Result<T, E>`]: ../../std/result/enum.Result.html
/// [`char`]: ../primitive.char.html /// [`char`]: ../../std/primitive.char.html
/// ///
/// Because `collect()` is so general, it can cause problems with type /// Because `collect()` is so general, it can cause problems with type
/// inference. As such, `collect()` is one of the few times you'll see /// inference. As such, `collect()` is one of the few times you'll see
@ -1412,7 +1412,7 @@ pub trait Iterator {
/// Note that we needed the `: Vec<i32>` on the left-hand side. This is because /// Note that we needed the `: Vec<i32>` on the left-hand side. This is because
/// we could collect into, for example, a [`VecDeque<T>`] instead: /// we could collect into, for example, a [`VecDeque<T>`] instead:
/// ///
/// [`VecDeque<T>`]: ../collections/struct.VecDeque.html /// [`VecDeque<T>`]: ../../std/collections/struct.VecDeque.html
/// ///
/// ``` /// ```
/// use std::collections::VecDeque; /// use std::collections::VecDeque;

View file

@ -206,8 +206,8 @@ macro_rules! try {
/// ///
/// See [`std::fmt`][fmt] for more information on format syntax. /// See [`std::fmt`][fmt] for more information on format syntax.
/// ///
/// [fmt]: fmt/index.html /// [fmt]: ../std/fmt/index.html
/// [write]: io/trait.Write.html /// [write]: ../std/io/trait.Write.html
/// ///
/// # Examples /// # Examples
/// ///
@ -232,8 +232,8 @@ macro_rules! write {
/// ///
/// See [`std::fmt`][fmt] for more information on format syntax. /// See [`std::fmt`][fmt] for more information on format syntax.
/// ///
/// [fmt]: fmt/index.html /// [fmt]: ../std/fmt/index.html
/// [write]: io/trait.Write.html /// [write]: ../std/io/trait.Write.html
/// ///
/// # Examples /// # Examples
/// ///

View file

@ -2179,8 +2179,8 @@ impl usize {
/// This `enum` is used as the return type for [`f32::classify()`] and [`f64::classify()`]. See /// This `enum` is used as the return type for [`f32::classify()`] and [`f64::classify()`]. See
/// their documentation for more. /// their documentation for more.
/// ///
/// [`f32::classify()`]: ../primitive.f32.html#method.classify /// [`f32::classify()`]: ../../std/primitive.f32.html#method.classify
/// [`f64::classify()`]: ../primitive.f64.html#method.classify /// [`f64::classify()`]: ../../std/primitive.f64.html#method.classify
#[derive(Copy, Clone, PartialEq, Debug)] #[derive(Copy, Clone, PartialEq, Debug)]
#[stable(feature = "rust1", since = "1.0.0")] #[stable(feature = "rust1", since = "1.0.0")]
pub enum FpCategory { pub enum FpCategory {
@ -2411,7 +2411,7 @@ fn from_str_radix<T: FromStrRadixHelper>(src: &str, radix: u32)
/// This error is used as the error type for the `from_str_radix()` functions /// This error is used as the error type for the `from_str_radix()` functions
/// on the primitive integer types, such as [`i8::from_str_radix()`]. /// on the primitive integer types, such as [`i8::from_str_radix()`].
/// ///
/// [`i8::from_str_radix()`]: ../std/primitive.i8.html#method.from_str_radix /// [`i8::from_str_radix()`]: ../../std/primitive.i8.html#method.from_str_radix
#[derive(Debug, Clone, PartialEq)] #[derive(Debug, Clone, PartialEq)]
#[stable(feature = "rust1", since = "1.0.0")] #[stable(feature = "rust1", since = "1.0.0")]
pub struct ParseIntError { kind: IntErrorKind } pub struct ParseIntError { kind: IntErrorKind }

View file

@ -908,6 +908,7 @@ impl<'a, T> ExactSizeIterator for IterMut<'a, T> {}
/// An internal abstraction over the splitting iterators, so that /// An internal abstraction over the splitting iterators, so that
/// splitn, splitn_mut etc can be implemented once. /// splitn, splitn_mut etc can be implemented once.
#[doc(hidden)]
trait SplitIter: DoubleEndedIterator { trait SplitIter: DoubleEndedIterator {
/// Mark the underlying iterator as complete, extracting the remaining /// Mark the underlying iterator as complete, extracting the remaining
/// portion of the slice. /// portion of the slice.

View file

@ -42,8 +42,8 @@ pub mod pattern;
/// [`str`]'s [`parse()`] method. See [`parse()`]'s documentation for examples. /// [`str`]'s [`parse()`] method. See [`parse()`]'s documentation for examples.
/// ///
/// [`from_str()`]: #tymethod.from_str /// [`from_str()`]: #tymethod.from_str
/// [`str`]: ../primitive.str.html /// [`str`]: ../../std/primitive.str.html
/// [`parse()`]: ../primitive.str.html#method.parse /// [`parse()`]: ../../std/primitive.str.html#method.parse
#[stable(feature = "rust1", since = "1.0.0")] #[stable(feature = "rust1", since = "1.0.0")]
pub trait FromStr: Sized { pub trait FromStr: Sized {
/// The associated error which can be returned from parsing. /// The associated error which can be returned from parsing.
@ -60,7 +60,7 @@ pub trait FromStr: Sized {
/// ///
/// Basic usage with [`i32`][ithirtytwo], a type that implements `FromStr`: /// Basic usage with [`i32`][ithirtytwo], a type that implements `FromStr`:
/// ///
/// [ithirtytwo]: ../primitive.i32.html /// [ithirtytwo]: ../../std/primitive.i32.html
/// ///
/// ``` /// ```
/// use std::str::FromStr; /// use std::str::FromStr;
@ -182,7 +182,7 @@ impl Utf8Error {
/// If you need a `String` instead of a `&str`, consider /// If you need a `String` instead of a `&str`, consider
/// [`String::from_utf8()`][string]. /// [`String::from_utf8()`][string].
/// ///
/// [string]: ../string/struct.String.html#method.from_utf8 /// [string]: ../../std/string/struct.String.html#method.from_utf8
/// ///
/// Because you can stack-allocate a `[u8; N]`, and you can take a `&[u8]` of /// Because you can stack-allocate a `[u8; N]`, and you can take a `&[u8]` of
/// it, this function is one way to have a stack-allocated string. There is /// it, this function is one way to have a stack-allocated string. There is
@ -322,7 +322,7 @@ Section: Iterators
/// ///
/// Created with the method [`chars()`]. /// Created with the method [`chars()`].
/// ///
/// [`chars()`]: ../primitive.str.html#method.chars /// [`chars()`]: ../../std/primitive.str.html#method.chars
#[derive(Clone)] #[derive(Clone)]
#[stable(feature = "rust1", since = "1.0.0")] #[stable(feature = "rust1", since = "1.0.0")]
pub struct Chars<'a> { pub struct Chars<'a> {
@ -531,7 +531,7 @@ impl<'a> CharIndices<'a> {
/// ///
/// Created with the method [`bytes()`]. /// Created with the method [`bytes()`].
/// ///
/// [`bytes()`]: ../primitive.str.html#method.bytes /// [`bytes()`]: ../../std/primitive.str.html#method.bytes
#[stable(feature = "rust1", since = "1.0.0")] #[stable(feature = "rust1", since = "1.0.0")]
#[derive(Clone)] #[derive(Clone)]
pub struct Bytes<'a>(Cloned<slice::Iter<'a, u8>>); pub struct Bytes<'a>(Cloned<slice::Iter<'a, u8>>);
@ -816,12 +816,12 @@ generate_pattern_iterators! {
forward: forward:
/// Created with the method [`split()`]. /// Created with the method [`split()`].
/// ///
/// [`split()`]: ../primitive.str.html#method.split /// [`split()`]: ../../std/primitive.str.html#method.split
struct Split; struct Split;
reverse: reverse:
/// Created with the method [`rsplit()`]. /// Created with the method [`rsplit()`].
/// ///
/// [`rsplit()`]: ../primitive.str.html#method.rsplit /// [`rsplit()`]: ../../std/primitive.str.html#method.rsplit
struct RSplit; struct RSplit;
stability: stability:
#[stable(feature = "rust1", since = "1.0.0")] #[stable(feature = "rust1", since = "1.0.0")]
@ -834,12 +834,12 @@ generate_pattern_iterators! {
forward: forward:
/// Created with the method [`split_terminator()`]. /// Created with the method [`split_terminator()`].
/// ///
/// [`split_terminator()`]: ../primitive.str.html#method.split_terminator /// [`split_terminator()`]: ../../std/primitive.str.html#method.split_terminator
struct SplitTerminator; struct SplitTerminator;
reverse: reverse:
/// Created with the method [`rsplit_terminator()`]. /// Created with the method [`rsplit_terminator()`].
/// ///
/// [`rsplit_terminator()`]: ../primitive.str.html#method.rsplit_terminator /// [`rsplit_terminator()`]: ../../std/primitive.str.html#method.rsplit_terminator
struct RSplitTerminator; struct RSplitTerminator;
stability: stability:
#[stable(feature = "rust1", since = "1.0.0")] #[stable(feature = "rust1", since = "1.0.0")]
@ -884,12 +884,12 @@ generate_pattern_iterators! {
forward: forward:
/// Created with the method [`splitn()`]. /// Created with the method [`splitn()`].
/// ///
/// [`splitn()`]: ../primitive.str.html#method.splitn /// [`splitn()`]: ../../std/primitive.str.html#method.splitn
struct SplitN; struct SplitN;
reverse: reverse:
/// Created with the method [`rsplitn()`]. /// Created with the method [`rsplitn()`].
/// ///
/// [`rsplitn()`]: ../primitive.str.html#method.rsplitn /// [`rsplitn()`]: ../../std/primitive.str.html#method.rsplitn
struct RSplitN; struct RSplitN;
stability: stability:
#[stable(feature = "rust1", since = "1.0.0")] #[stable(feature = "rust1", since = "1.0.0")]
@ -926,12 +926,12 @@ generate_pattern_iterators! {
forward: forward:
/// Created with the method [`match_indices()`]. /// Created with the method [`match_indices()`].
/// ///
/// [`match_indices()`]: ../primitive.str.html#method.match_indices /// [`match_indices()`]: ../../std/primitive.str.html#method.match_indices
struct MatchIndices; struct MatchIndices;
reverse: reverse:
/// Created with the method [`rmatch_indices()`]. /// Created with the method [`rmatch_indices()`].
/// ///
/// [`rmatch_indices()`]: ../primitive.str.html#method.rmatch_indices /// [`rmatch_indices()`]: ../../std/primitive.str.html#method.rmatch_indices
struct RMatchIndices; struct RMatchIndices;
stability: stability:
#[stable(feature = "str_match_indices", since = "1.5.0")] #[stable(feature = "str_match_indices", since = "1.5.0")]
@ -970,12 +970,12 @@ generate_pattern_iterators! {
forward: forward:
/// Created with the method [`matches()`]. /// Created with the method [`matches()`].
/// ///
/// [`matches()`]: ../primitive.str.html#method.matches /// [`matches()`]: ../../std/primitive.str.html#method.matches
struct Matches; struct Matches;
reverse: reverse:
/// Created with the method [`rmatches()`]. /// Created with the method [`rmatches()`].
/// ///
/// [`rmatches()`]: ../primitive.str.html#method.rmatches /// [`rmatches()`]: ../../std/primitive.str.html#method.rmatches
struct RMatches; struct RMatches;
stability: stability:
#[stable(feature = "str_matches", since = "1.2.0")] #[stable(feature = "str_matches", since = "1.2.0")]
@ -986,7 +986,7 @@ generate_pattern_iterators! {
/// Created with the method [`lines()`]. /// Created with the method [`lines()`].
/// ///
/// [`lines()`]: ../primitive.str.html#method.lines /// [`lines()`]: ../../std/primitive.str.html#method.lines
#[stable(feature = "rust1", since = "1.0.0")] #[stable(feature = "rust1", since = "1.0.0")]
#[derive(Clone)] #[derive(Clone)]
pub struct Lines<'a>(Map<SplitTerminator<'a, char>, LinesAnyMap>); pub struct Lines<'a>(Map<SplitTerminator<'a, char>, LinesAnyMap>);
@ -1016,7 +1016,7 @@ impl<'a> DoubleEndedIterator for Lines<'a> {
/// Created with the method [`lines_any()`]. /// Created with the method [`lines_any()`].
/// ///
/// [`lines_any()`]: ../primitive.str.html#method.lines_any /// [`lines_any()`]: ../../std/primitive.str.html#method.lines_any
#[stable(feature = "rust1", since = "1.0.0")] #[stable(feature = "rust1", since = "1.0.0")]
#[rustc_deprecated(since = "1.4.0", reason = "use lines()/Lines instead now")] #[rustc_deprecated(since = "1.4.0", reason = "use lines()/Lines instead now")]
#[derive(Clone)] #[derive(Clone)]

View file

@ -70,6 +70,7 @@ mod rand_impls;
// needed by librand; this is necessary because librand doesn't // needed by librand; this is necessary because librand doesn't
// depend on libstd. This will go away when librand is integrated // depend on libstd. This will go away when librand is integrated
// into libstd. // into libstd.
#[doc(hidden)]
trait FloatMath : Sized { trait FloatMath : Sized {
fn exp(self) -> Self; fn exp(self) -> Self;
fn ln(self) -> Self; fn ln(self) -> Self;

View file

@ -19,7 +19,7 @@
//! [Unicode code point]: http://www.unicode.org/glossary/#code_point //! [Unicode code point]: http://www.unicode.org/glossary/#code_point
//! //!
//! This module exists for technical reasons, the primary documentation for //! This module exists for technical reasons, the primary documentation for
//! `char` is directly on [the `char` primitive type](../primitive.char.html) //! `char` is directly on [the `char` primitive type](../../std/primitive.char.html)
//! itself. //! itself.
//! //!
//! This module is the home of the iterator implementations for the iterators //! This module is the home of the iterator implementations for the iterators
@ -46,8 +46,8 @@ pub use tables::UNICODE_VERSION;
/// This `struct` is created by the [`to_lowercase()`] method on [`char`]. See /// This `struct` is created by the [`to_lowercase()`] method on [`char`]. See
/// its documentation for more. /// its documentation for more.
/// ///
/// [`to_lowercase()`]: ../primitive.char.html#method.to_lowercase /// [`to_lowercase()`]: ../../std/primitive.char.html#method.to_lowercase
/// [`char`]: ../primitive.char.html /// [`char`]: ../../std/primitive.char.html
#[stable(feature = "rust1", since = "1.0.0")] #[stable(feature = "rust1", since = "1.0.0")]
pub struct ToLowercase(CaseMappingIter); pub struct ToLowercase(CaseMappingIter);
@ -64,8 +64,8 @@ impl Iterator for ToLowercase {
/// This `struct` is created by the [`to_uppercase()`] method on [`char`]. See /// This `struct` is created by the [`to_uppercase()`] method on [`char`]. See
/// its documentation for more. /// its documentation for more.
/// ///
/// [`to_uppercase()`]: ../primitive.char.html#method.to_uppercase /// [`to_uppercase()`]: ../../std/primitive.char.html#method.to_uppercase
/// [`char`]: ../primitive.char.html /// [`char`]: ../../std/primitive.char.html
#[stable(feature = "rust1", since = "1.0.0")] #[stable(feature = "rust1", since = "1.0.0")]
pub struct ToUppercase(CaseMappingIter); pub struct ToUppercase(CaseMappingIter);
@ -968,6 +968,6 @@ impl<I: Iterator<Item=u16>> Iterator for DecodeUtf16<I> {
/// `U+FFFD REPLACEMENT CHARACTER` (<28>) is used in Unicode to represent a decoding error. /// `U+FFFD REPLACEMENT CHARACTER` (<28>) is used in Unicode to represent a decoding error.
/// It can occur, for example, when giving ill-formed UTF-8 bytes to /// It can occur, for example, when giving ill-formed UTF-8 bytes to
/// [`String::from_utf8_lossy`](../string/struct.String.html#method.from_utf8_lossy). /// [`String::from_utf8_lossy`](../../std/string/struct.String.html#method.from_utf8_lossy).
#[unstable(feature = "decode_utf16", reason = "recently added", issue = "27830")] #[unstable(feature = "decode_utf16", reason = "recently added", issue = "27830")]
pub const REPLACEMENT_CHARACTER: char = '\u{FFFD}'; pub const REPLACEMENT_CHARACTER: char = '\u{FFFD}';

View file

@ -262,7 +262,7 @@ impl f32 {
/// ///
/// assert!(abs_difference <= f32::EPSILON); /// assert!(abs_difference <= f32::EPSILON);
/// ``` /// ```
/// [floating-point]: ../../../../../reference.html#machine-types /// [floating-point]: ../reference.html#machine-types
#[unstable(feature = "float_extras", reason = "signature is undecided", #[unstable(feature = "float_extras", reason = "signature is undecided",
issue = "27752")] issue = "27752")]
#[inline] #[inline]

View file

@ -206,7 +206,7 @@ impl f64 {
/// ///
/// assert!(abs_difference < 1e-10); /// assert!(abs_difference < 1e-10);
/// ``` /// ```
/// [floating-point]: ../../../../../reference.html#machine-types /// [floating-point]: ../reference.html#machine-types
#[unstable(feature = "float_extras", reason = "signature is undecided", #[unstable(feature = "float_extras", reason = "signature is undecided",
issue = "27752")] issue = "27752")]
#[inline] #[inline]

View file

@ -27,11 +27,11 @@
/// assert!(!bool_val); /// assert!(!bool_val);
/// ``` /// ```
/// ///
/// [`assert!`]: std/macro.assert!.html /// [`assert!`]: macro.assert!.html
/// [`if` conditionals]: ../../book/if.html /// [`if` conditionals]: ../book/if.html
/// [`BitAnd`]: ../ops/trait.BitAnd.html /// [`BitAnd`]: ops/trait.BitAnd.html
/// [`BitOr`]: ../ops/trait.BitOr.html /// [`BitOr`]: ops/trait.BitOr.html
/// [`Not`]: ../ops/trait.Not.html /// [`Not`]: ops/trait.Not.html
/// ///
/// # Examples /// # Examples
/// ///
@ -54,7 +54,7 @@
/// } /// }
/// ``` /// ```
/// ///
/// Also, since `bool` implements the [`Copy`](../marker/trait.Copy.html) trait, we don't /// Also, since `bool` implements the [`Copy`](marker/trait.Copy.html) trait, we don't
/// have to worry about the move semantics (just like the integer and float primitives). /// have to worry about the move semantics (just like the integer and float primitives).
mod prim_bool { } mod prim_bool { }
@ -421,7 +421,7 @@ mod prim_str { }
/// assert_eq!(tuple.2, 'c'); /// assert_eq!(tuple.2, 'c');
/// ``` /// ```
/// ///
/// For more about tuples, see [the book](../../book/primitive-types.html#tuples). /// For more about tuples, see [the book](../book/primitive-types.html#tuples).
/// ///
/// # Trait implementations /// # Trait implementations
/// ///
@ -437,14 +437,14 @@ mod prim_str { }
/// * [`Default`] /// * [`Default`]
/// * [`Hash`] /// * [`Hash`]
/// ///
/// [`Clone`]: ../clone/trait.Clone.html /// [`Clone`]: clone/trait.Clone.html
/// [`PartialEq`]: ../cmp/trait.PartialEq.html /// [`PartialEq`]: cmp/trait.PartialEq.html
/// [`Eq`]: ../cmp/trait.Eq.html /// [`Eq`]: cmp/trait.Eq.html
/// [`PartialOrd`]: ../cmp/trait.PartialOrd.html /// [`PartialOrd`]: cmp/trait.PartialOrd.html
/// [`Ord`]: ../cmp/trait.Ord.html /// [`Ord`]: cmp/trait.Ord.html
/// [`Debug`]: ../fmt/trait.Debug.html /// [`Debug`]: fmt/trait.Debug.html
/// [`Default`]: ../default/trait.Default.html /// [`Default`]: default/trait.Default.html
/// [`Hash`]: ../hash/trait.Hash.html /// [`Hash`]: hash/trait.Hash.html
/// ///
/// Due to a temporary restriction in Rust's type system, these traits are only /// Due to a temporary restriction in Rust's type system, these traits are only
/// implemented on tuples of arity 32 or less. In the future, this may change. /// implemented on tuples of arity 32 or less. In the future, this may change.