@@ -88,26 +88,28 @@ Book][unstable-doc-cfg] and [its tracking issue][issue-doc-cfg].
88
88
[ unstable-doc-cfg ] : ../unstable-book/language-features/doc-cfg.html
89
89
[ issue-doc-cfg ] : https://github.com/rust-lang/rust/issues/43781
90
90
91
- ### Adding your trait to the "Important Traits" dialog
92
-
93
- Rustdoc keeps a list of a few traits that are believed to be "fundamental" to a given type when
94
- implemented on it. These traits are intended to be the primary interface for their types, and are
95
- often the only thing available to be documented on their types. For this reason, Rustdoc will track
96
- when a given type implements one of these traits and call special attention to it when a function
97
- returns one of these types. This is the "Important Traits" dialog, visible as a circle-i button next
98
- to the function, which, when clicked, shows the dialog.
99
-
100
- In the standard library, the traits that qualify for inclusion are ` Iterator ` , ` io::Read ` , and
101
- ` io::Write ` . However, rather than being implemented as a hard-coded list, these traits have a
102
- special marker attribute on them: ` #[doc(spotlight)] ` . This means that you could apply this
103
- attribute to your own trait to include it in the "Important Traits" dialog in documentation.
104
-
105
- The ` #[doc(spotlight)] ` attribute currently requires the ` #![feature(doc_spotlight)] ` feature gate.
106
- For more information, see [ its chapter in the Unstable Book] [ unstable-spotlight ] and [ its tracking
107
- issue] [ issue-spotlight ] .
108
-
109
- [ unstable-spotlight ] : ../unstable-book/language-features/doc-spotlight.html
110
- [ issue-spotlight ] : https://github.com/rust-lang/rust/issues/45040
91
+ ### Adding your trait to the "Notable traits" dialog
92
+
93
+ Rustdoc keeps a list of a few traits that are believed to be "fundamental" to
94
+ types that implement them. These traits are intended to be the primary interface
95
+ for their implementers, and are often most of the API available to be documented
96
+ on their types. For this reason, Rustdoc will track when a given type implements
97
+ one of these traits and call special attention to it when a function returns one
98
+ of these types. This is the "Notable traits" dialog, accessible as a circled ` i `
99
+ button next to the function, which, when clicked, shows the dialog.
100
+
101
+ In the standard library, some of the traits that are part of this list are
102
+ ` Iterator ` , ` Future ` , ` io::Read ` , and ` io::Write ` . However, rather than being
103
+ implemented as a hard-coded list, these traits have a special marker attribute
104
+ on them: ` #[doc(notable_trait)] ` . This means that you can apply this attribute
105
+ to your own trait to include it in the "Notable traits" dialog in documentation.
106
+
107
+ The ` #[doc(notable_trait)] ` attribute currently requires the ` #![feature(doc_notable_trait)] `
108
+ feature gate. For more information, see [ its chapter in the Unstable Book] [ unstable-notable_trait ]
109
+ and [ its tracking issue] [ issue-notable_trait ] .
110
+
111
+ [ unstable-notable_trait ] : ../unstable-book/language-features/doc-notable-trait.html
112
+ [ issue-notable_trait ] : https://github.com/rust-lang/rust/issues/45040
111
113
112
114
### Exclude certain dependencies from documentation
113
115
0 commit comments