@@ -39,7 +39,7 @@ use crate::io;
3939/// [`stack_size`]: Builder::stack_size
4040/// [`name`]: Builder::name
4141/// [`spawn`]: Builder::spawn
42- /// [`thread::spawn`]: spawn
42+ /// [`thread::spawn`]: super:: spawn
4343/// [`io::Result`]: crate::io::Result
4444/// [`unwrap`]: crate::result::Result::unwrap
4545/// [naming-threads]: ./index.html#naming-threads
@@ -133,10 +133,12 @@ impl Builder {
133133 self
134134 }
135135
136- /// Disables running and inheriting [spawn hooks](add_spawn_hook) .
136+ /// Disables running and inheriting [spawn hooks].
137137 ///
138138 /// Use this if the parent thread is in no way relevant for the child thread.
139139 /// For example, when lazily spawning threads for a thread pool.
140+ ///
141+ /// [spawn hooks]: super::add_spawn_hook
140142 #[ unstable( feature = "thread_spawn_hook" , issue = "132951" ) ]
141143 pub fn no_hooks ( mut self ) -> Builder {
142144 self . no_hooks = true ;
@@ -151,7 +153,7 @@ impl Builder {
151153 /// thread finishes). The join handle can be used to block on
152154 /// termination of the spawned thread, including recovering its panics.
153155 ///
154- /// For a more complete documentation see [`thread::spawn`][`spawn`] .
156+ /// For a more complete documentation see [`thread::spawn`].
155157 ///
156158 /// # Errors
157159 ///
@@ -178,6 +180,9 @@ impl Builder {
178180 ///
179181 /// handler.join().unwrap();
180182 /// ```
183+ ///
184+ /// [`thread::spawn`]: super::spawn
185+ /// [`spawn`]: super::spawn
181186 #[ stable( feature = "rust1" , since = "1.0.0" ) ]
182187 #[ cfg_attr( miri, track_caller) ] // even without panics, this helps for Miri backtraces
183188 pub fn spawn < F , T > ( self , f : F ) -> io:: Result < JoinHandle < T > >
@@ -199,7 +204,7 @@ impl Builder {
199204 ///
200205 /// This method is identical to [`thread::Builder::spawn`][`Builder::spawn`],
201206 /// except for the relaxed lifetime bounds, which render it unsafe.
202- /// For a more complete documentation see [`thread::spawn`][`spawn`] .
207+ /// For a more complete documentation see [`thread::spawn`].
203208 ///
204209 /// # Errors
205210 ///
@@ -221,7 +226,7 @@ impl Builder {
221226 /// data is dropped
222227 /// - use only types with `'static` lifetime bounds, i.e., those with no or only
223228 /// `'static` references (both [`thread::Builder::spawn`][`Builder::spawn`]
224- /// and [`thread::spawn`][`spawn`] enforce this property statically)
229+ /// and [`thread::spawn`] enforce this property statically)
225230 ///
226231 /// # Examples
227232 ///
@@ -246,6 +251,8 @@ impl Builder {
246251 /// ```
247252 ///
248253 /// [`io::Result`]: crate::io::Result
254+ /// [`thread::spawn`]: super::spawn
255+ /// [`spawn`]: super::spawn
249256 #[ stable( feature = "thread_spawn_unchecked" , since = "1.82.0" ) ]
250257 #[ cfg_attr( miri, track_caller) ] // even without panics, this helps for Miri backtraces
251258 pub unsafe fn spawn_unchecked < F , T > ( self , f : F ) -> io:: Result < JoinHandle < T > >
0 commit comments