We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Ready::unwrap()
1 parent 208ebfc commit 1800c0cCopy full SHA for 1800c0c
library/core/src/future/ready.rs
@@ -37,13 +37,13 @@ impl<T> Ready<T> {
37
/// use std::future;
38
///
39
/// let a = future::ready(1);
40
- /// assert_eq!(a.into_inner(), 1);
+ /// assert_eq!(a.unwrap(), 1);
41
/// ```
42
#[stable(feature = "ready_into_inner", since = "CURRENT_RUSTC_VERSION")]
43
#[must_use]
44
#[inline]
45
- pub fn into_inner(self) -> T {
46
- self.0.expect("Called `into_inner()` on `Ready` after completion")
+ pub fn unwrap(self) -> T {
+ self.0.expect("Called `unwrap()` on `Ready` after completion")
47
}
48
49
0 commit comments