Skip to content

Commit ab3996a

Browse files
time: update outdated docs of Wheel (#7749)
1 parent c03a37f commit ab3996a

File tree

3 files changed

+12
-19
lines changed

3 files changed

+12
-19
lines changed

tokio-util/src/time/wheel/mod.rs

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -10,15 +10,17 @@ use std::fmt::Debug;
1010

1111
/// Timing wheel implementation.
1212
///
13-
/// This type provides the hashed timing wheel implementation that backs `Timer`
14-
/// and `DelayQueue`.
13+
/// This type provides the hashed timing wheel implementation that backs
14+
/// [`DelayQueue`].
1515
///
1616
/// The structure is generic over `T: Stack`. This allows handling timeout data
1717
/// being stored on the heap or in a slab. In order to support the latter case,
1818
/// the slab must be passed into each function allowing the implementation to
1919
/// lookup timer entries.
2020
///
21-
/// See `Timer` documentation for some implementation notes.
21+
/// See `Driver` documentation for some implementation notes.
22+
///
23+
/// [`DelayQueue`]: crate::time::DelayQueue
2224
#[derive(Debug)]
2325
pub(crate) struct Wheel<T> {
2426
/// The number of milliseconds elapsed since the wheel started.

tokio/src/runtime/time/wheel/mod.rs

Lines changed: 4 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -12,15 +12,12 @@ use super::EntryList;
1212

1313
/// Timing wheel implementation.
1414
///
15-
/// This type provides the hashed timing wheel implementation that backs `Timer`
16-
/// and `DelayQueue`.
15+
/// This type provides the hashed timing wheel implementation that backs
16+
/// [`Driver`].
1717
///
18-
/// The structure is generic over `T: Stack`. This allows handling timeout data
19-
/// being stored on the heap or in a slab. In order to support the latter case,
20-
/// the slab must be passed into each function allowing the implementation to
21-
/// lookup timer entries.
18+
/// See [`Driver`] documentation for some implementation notes.
2219
///
23-
/// See `Timer` documentation for some implementation notes.
20+
/// [`Driver`]: crate::runtime::time::Driver
2421
#[derive(Debug)]
2522
pub(crate) struct Wheel {
2623
/// The number of milliseconds elapsed since the wheel started.

tokio/src/runtime/time_alt/wheel/mod.rs

Lines changed: 3 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -7,17 +7,11 @@ use super::{EntryHandle, EntryList, WakeQueue};
77

88
use std::array;
99

10-
/// Timing wheel implementation.
10+
/// Hashed timing wheel implementation.
1111
///
12-
/// This type provides the hashed timing wheel implementation that backs `Timer`
13-
/// and `DelayQueue`.
12+
/// See [`Driver`] documentation for some implementation notes.
1413
///
15-
/// The structure is generic over `T: Stack`. This allows handling timeout data
16-
/// being stored on the heap or in a slab. In order to support the latter case,
17-
/// the slab must be passed into each function allowing the implementation to
18-
/// lookup timer entries.
19-
///
20-
/// See `Timer` documentation for some implementation notes.
14+
/// [`Driver`]: crate::runtime::time::Driver
2115
#[derive(Debug)]
2216
pub(crate) struct Wheel {
2317
/// The number of milliseconds elapsed since the wheel started.

0 commit comments

Comments
 (0)