Make throttle an unstable feature

pull/356/head
Wouter Geraedts 5 years ago
parent b591fc68bd
commit 139a34b685

@ -60,7 +60,6 @@ mod skip_while;
mod step_by; mod step_by;
mod take; mod take;
mod take_while; mod take_while;
mod throttle;
mod try_fold; mod try_fold;
mod try_for_each; mod try_for_each;
mod zip; mod zip;
@ -107,16 +106,15 @@ pub use skip_while::SkipWhile;
pub use step_by::StepBy; pub use step_by::StepBy;
pub use take::Take; pub use take::Take;
pub use take_while::TakeWhile; pub use take_while::TakeWhile;
pub use throttle::Throttle;
pub use zip::Zip; pub use zip::Zip;
use std::cmp::Ordering; use std::cmp::Ordering;
use std::marker::PhantomData; use std::marker::PhantomData;
use std::time::Duration;
cfg_unstable! { cfg_unstable! {
use std::future::Future; use std::future::Future;
use std::pin::Pin; use std::pin::Pin;
use std::time::Duration;
use crate::stream::into_stream::IntoStream; use crate::stream::into_stream::IntoStream;
use crate::stream::{FromStream, Product, Sum}; use crate::stream::{FromStream, Product, Sum};
@ -125,11 +123,13 @@ cfg_unstable! {
pub use flatten::Flatten; pub use flatten::Flatten;
pub use flat_map::FlatMap; pub use flat_map::FlatMap;
pub use timeout::{TimeoutError, Timeout}; pub use timeout::{TimeoutError, Timeout};
pub use throttle::Throttle;
mod merge; mod merge;
mod flatten; mod flatten;
mod flat_map; mod flat_map;
mod timeout; mod timeout;
mod throttle;
} }
extension_trait! { extension_trait! {
@ -315,6 +315,7 @@ extension_trait! {
TakeWhile::new(self, predicate) TakeWhile::new(self, predicate)
} }
#[cfg(all(feature = "default", feature = "unstable"))]
#[doc = r#" #[doc = r#"
Limit the amount of items yielded per timeslice in a stream. Limit the amount of items yielded per timeslice in a stream.

Loading…
Cancel
Save