mirror of
https://github.com/tokio-rs/tokio.git
synced 2026-08-27 00:00:12 +02:00
Update Tokio to Rust 2018 (#1082)
This commit is contained in:
@@ -1,10 +1,10 @@
|
||||
use tokio_executor::park::{Park, Unpark};
|
||||
|
||||
use log::warn;
|
||||
use std::error::Error;
|
||||
use std::time::Duration;
|
||||
use tokio_executor::park::{Park, Unpark};
|
||||
|
||||
pub(crate) type BoxPark = Box<Park<Unpark = BoxUnpark, Error = ()> + Send>;
|
||||
pub(crate) type BoxUnpark = Box<Unpark>;
|
||||
pub(crate) type BoxPark = Box<dyn Park<Unpark = BoxUnpark, Error = ()> + Send>;
|
||||
pub(crate) type BoxUnpark = Box<dyn Unpark>;
|
||||
|
||||
pub(crate) struct BoxedPark<T>(T);
|
||||
|
||||
|
||||
@@ -1,10 +1,8 @@
|
||||
use tokio_executor::park::{Park, Unpark};
|
||||
|
||||
use crossbeam_utils::sync::{Parker, Unparker};
|
||||
use std::error::Error;
|
||||
use std::fmt;
|
||||
use std::time::Duration;
|
||||
|
||||
use crossbeam_utils::sync::{Parker, Unparker};
|
||||
use tokio_executor::park::{Park, Unpark};
|
||||
|
||||
/// Parks the thread.
|
||||
#[derive(Debug)]
|
||||
@@ -85,7 +83,7 @@ impl Unpark for DefaultUnpark {
|
||||
// ===== impl ParkError =====
|
||||
|
||||
impl fmt::Display for ParkError {
|
||||
fn fmt(&self, fmt: &mut fmt::Formatter) -> fmt::Result {
|
||||
fn fmt(&self, fmt: &mut fmt::Formatter<'_>) -> fmt::Result {
|
||||
self.description().fmt(fmt)
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user