Run denali server thread.
This commit is contained in:
parent
10e536acab
commit
a5cdd23f0b
7 changed files with 104 additions and 19 deletions
|
|
@ -28,11 +28,11 @@ pub struct Task {
|
|||
id: TaskId,
|
||||
// FIXME: This only needs to be sync because of the CURRENT_EXECUTOR
|
||||
// needing to be shared between threads.
|
||||
future: Pin<Box<dyn Future<Output = ()> + Sync>>,
|
||||
future: Pin<Box<dyn Future<Output = ()> + Sync + Send>>,
|
||||
}
|
||||
|
||||
impl Task {
|
||||
pub fn new(future: impl Future<Output = ()> + Sync + 'static) -> Task {
|
||||
pub fn new(future: impl Future<Output = ()> + Sync + Send + 'static) -> Task {
|
||||
Task {
|
||||
id: TaskId::new(),
|
||||
future: Box::pin(future),
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue