mirror of
https://github.com/tokio-rs/tokio.git
synced 2026-08-25 00:00:18 +02:00
re-export tokio-current-thread::spawn (#579)
Re-export it inside the tokio::runtime::current_thread, as the original place (tokio::executor::current_thread) is hidden from documentation and users need some way to spawn non-Send futures.
This commit is contained in:
committed by
Carl Lerche
parent
82c5baa09b
commit
6e45e0ac61
+4
-1
@@ -39,7 +39,10 @@
|
||||
//! [`Executor`]: trait.Executor.html
|
||||
//! [`spawn`]: fn.spawn.html
|
||||
|
||||
#[deprecated(since = "0.1.8", note = "use tokio-current-thread crate instead")]
|
||||
#[deprecated(
|
||||
since = "0.1.8",
|
||||
note = "use tokio-current-thread crate or functions in tokio::runtime::current_thread instead",
|
||||
)]
|
||||
#[doc(hidden)]
|
||||
pub mod current_thread;
|
||||
|
||||
|
||||
@@ -71,6 +71,7 @@ mod runtime;
|
||||
|
||||
pub use self::builder::Builder;
|
||||
pub use self::runtime::{Runtime, Handle};
|
||||
pub use tokio_current_thread::spawn;
|
||||
|
||||
use futures::Future;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user