mirror of
https://github.com/rust-lang/rust.git
synced 2026-05-17 05:25:37 +03:00
Add doc for impl From for Waker
This commit is contained in:
@@ -188,6 +188,13 @@ pub fn will_wake_nonlocal(&self, other: &Waker) -> bool {
|
||||
}
|
||||
|
||||
impl From<LocalWaker> for Waker {
|
||||
/// Converts a [`LocalWaker`] into a [`Waker`].
|
||||
///
|
||||
/// This conversion forgets local waker and allocates a new waker with
|
||||
/// the same inner.
|
||||
///
|
||||
/// [`LocalWaker`]: struct.LocalWaker.html
|
||||
/// [`Waker`]: struct.Waker.html
|
||||
#[inline]
|
||||
fn from(local_waker: LocalWaker) -> Self {
|
||||
local_waker.0
|
||||
|
||||
Reference in New Issue
Block a user