diff --git a/futures-core/src/stream.rs b/futures-core/src/stream.rs index 4a13e3bd7d..3900af3574 100644 --- a/futures-core/src/stream.rs +++ b/futures-core/src/stream.rs @@ -134,6 +134,15 @@ where } } +/// An owned dynamically typed [`FusedStream`] for use in cases where you can't +/// statically type your result or need to add some indirection. +#[cfg(feature = "alloc")] +pub type BoxFusedStream<'a, T> = Pin + Send + 'a>>; + +/// `BoxFusedStream`, but without the `Send` requirement. +#[cfg(feature = "alloc")] +pub type LocalBoxFusedStream<'a, T> = Pin + 'a>>; + /// A stream which tracks whether or not the underlying stream /// should no longer be polled. ///