@@ -275,6 +275,7 @@ pub trait Stream {
275275 /// This combinator does no guarding against overflows.
276276 ///
277277 /// # Examples
278+ ///
278279 /// ```
279280 /// # fn main() { async_std::task::block_on(async {
280281 /// #
@@ -291,6 +292,7 @@ pub trait Stream {
291292 ///
292293 /// #
293294 /// # }) }
295+ /// ```
294296 fn enumerate ( self ) -> Enumerate < Self >
295297 where
296298 Self : Sized ,
@@ -357,14 +359,15 @@ pub trait Stream {
357359 done : false ,
358360 }
359361 }
362+
360363 /// Creates a stream that uses a predicate to determine if an element
361364 /// should be yeilded.
362365 ///
363366 /// # Examples
364367 ///
365368 /// Basic usage:
366369 ///
367- ///```
370+ /// ```
368371 /// # fn main() { async_std::task::block_on(async {
369372 /// #
370373 /// use std::collections::VecDeque;
@@ -378,6 +381,7 @@ pub trait Stream {
378381 /// assert_eq!(s.next().await, None);
379382 /// #
380383 /// # }) }
384+ /// ```
381385 fn filter < P > ( self , predicate : P ) -> Filter < Self , P , Self :: Item >
382386 where
383387 Self : Sized ,
@@ -415,6 +419,7 @@ pub trait Stream {
415419 /// assert_eq!(end, None);
416420 /// #
417421 /// # }) }
422+ /// ```
418423 fn filter_map < B , F > ( self , f : F ) -> FilterMap < Self , F , Self :: Item , B >
419424 where
420425 Self : Sized ,
@@ -801,6 +806,11 @@ pub trait Stream {
801806 ///
802807 /// ## Examples
803808 ///
809+ /// ```
810+ /// # fn main() { async_std::task::block_on(async {
811+ /// #
812+ /// use std::collections::VecDeque;
813+ /// use async_std::stream::Stream;
804814 /// let s: VecDeque<usize> = vec![1, 2, 3].into_iter().collect();
805815 /// let mut skipped = s.skip(2);
806816 ///
0 commit comments