diff options
| author | Michael Howell <michael@notriddle.com> | 2022-06-16 09:50:57 -0700 | 
|---|---|---|
| committer | Michael Howell <michael@notriddle.com> | 2022-07-17 16:32:06 -0700 | 
| commit | 1169832f2ff1ce740dc3d68de2df3745ec4e1aef (patch) | |
| tree | 787992af670a5860306399e1fdc94e5818dbc0fc /library/core/src | |
| parent | 263edd43c5255084292329423c61a9d69715ebfa (diff) | |
| download | rust-1169832f2ff1ce740dc3d68de2df3745ec4e1aef.tar.gz rust-1169832f2ff1ce740dc3d68de2df3745ec4e1aef.zip | |
rustdoc: extend `#[doc(tuple_variadic)]` to fn pointers
The attribute is also renamed `fake_variadic`.
Diffstat (limited to 'library/core/src')
| -rw-r--r-- | library/core/src/fmt/mod.rs | 2 | ||||
| -rw-r--r-- | library/core/src/hash/mod.rs | 2 | ||||
| -rw-r--r-- | library/core/src/primitive_docs.rs | 4 | ||||
| -rw-r--r-- | library/core/src/tuple.rs | 2 | 
4 files changed, 5 insertions, 5 deletions
| diff --git a/library/core/src/fmt/mod.rs b/library/core/src/fmt/mod.rs index 6c3bb7229e5..372141e0933 100644 --- a/library/core/src/fmt/mod.rs +++ b/library/core/src/fmt/mod.rs @@ -2562,7 +2562,7 @@ macro_rules! tuple { macro_rules! maybe_tuple_doc { ($a:ident @ #[$meta:meta] $item:item) => { - #[doc(tuple_variadic)] + #[cfg_attr(not(bootstrap), doc(fake_variadic))] #[doc = "This trait is implemented for tuples up to twelve items long."] #[$meta] $item diff --git a/library/core/src/hash/mod.rs b/library/core/src/hash/mod.rs index cf428e0b1cf..5974562aced 100644 --- a/library/core/src/hash/mod.rs +++ b/library/core/src/hash/mod.rs @@ -900,7 +900,7 @@ mod impls { macro_rules! maybe_tuple_doc { ($a:ident @ #[$meta:meta] $item:item) => { - #[doc(tuple_variadic)] + #[cfg_attr(not(bootstrap), doc(fake_variadic))] #[doc = "This trait is implemented for tuples up to twelve items long."] #[$meta] $item diff --git a/library/core/src/primitive_docs.rs b/library/core/src/primitive_docs.rs index 401c8159988..4f08b562685 100644 --- a/library/core/src/primitive_docs.rs +++ b/library/core/src/primitive_docs.rs @@ -996,7 +996,7 @@ impl<T> (T,) {} // Fake impl that's only really used for docs. #[cfg(doc)] #[stable(feature = "rust1", since = "1.0.0")] -#[doc(tuple_variadic)] +#[cfg_attr(not(bootstrap), doc(fake_variadic))] /// This trait is implemented on arbitrary-length tuples. impl<T: Clone> Clone for (T,) { fn clone(&self) -> Self { @@ -1007,7 +1007,7 @@ impl<T: Clone> Clone for (T,) { // Fake impl that's only really used for docs. #[cfg(doc)] #[stable(feature = "rust1", since = "1.0.0")] -#[doc(tuple_variadic)] +#[cfg_attr(not(bootstrap), doc(fake_variadic))] /// This trait is implemented on arbitrary-length tuples. impl<T: Copy> Copy for (T,) { // empty diff --git a/library/core/src/tuple.rs b/library/core/src/tuple.rs index b664b0bb866..d189e6400f1 100644 --- a/library/core/src/tuple.rs +++ b/library/core/src/tuple.rs @@ -107,7 +107,7 @@ macro_rules! tuple_impls { // Otherwise, it hides the docs entirely. macro_rules! maybe_tuple_doc { ($a:ident @ #[$meta:meta] $item:item) => { - #[doc(tuple_variadic)] + #[cfg_attr(not(bootstrap), doc(fake_variadic))] #[doc = "This trait is implemented for tuples up to twelve items long."] #[$meta] $item | 
