Skip to content

Commit

Permalink
doc(alias) pending() to never (#2613)
Browse files Browse the repository at this point in the history
It can be legitimately to look for the future that _never_ resolves using the name `never`. This PR ensures `pending()` shows up when making such queries.
  • Loading branch information
danielhenrymantilla committed Jul 7, 2022
1 parent 183f8c6 commit bfb4b9c
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions futures-util/src/future/pending.rs
Expand Up @@ -33,6 +33,7 @@ impl<T> FusedFuture for Pending<T> {
/// unreachable!();
/// # });
/// ```
#[cfg_attr(docsrs, doc(alias = "never"))]
pub fn pending<T>() -> Pending<T> {
assert_future::<T, _>(Pending { _data: marker::PhantomData })
}
Expand Down

0 comments on commit bfb4b9c

Please sign in to comment.