diff --git a/src/future/client.rs b/src/future/client.rs index 7d1ae1b..85cf880 100644 --- a/src/future/client.rs +++ b/src/future/client.rs @@ -120,9 +120,9 @@ impl Clone for Client } impl Service for Client - where Req: Serialize + Sync + Send + 'static, - Resp: Deserialize + Sync + Send + 'static, - E: Deserialize + Sync + Send + 'static + where Req: Serialize + Send + 'static, + Resp: Deserialize + Send + 'static, + E: Deserialize + Send + 'static { type Request = Req; type Response = Resp; @@ -147,9 +147,9 @@ impl Client E: Deserialize + 'static { fn bind(handle: &reactor::Handle, tcp: StreamType, max_payload_size: u64) -> Self - where Req: Serialize + Sync + Send + 'static, - Resp: Deserialize + Sync + Send + 'static, - E: Deserialize + Sync + Send + 'static + where Req: Serialize + Send + 'static, + Resp: Deserialize + Send + 'static, + E: Deserialize + Send + 'static { let inner = Proto::new(max_payload_size).bind_client(&handle, tcp); Client { inner } @@ -187,9 +187,9 @@ pub type ConnectFuture = fn(futures::Canceled) -> io::Error>>; impl ClientExt for Client - where Req: Serialize + Sync + Send + 'static, - Resp: Deserialize + Sync + Send + 'static, - E: Deserialize + Sync + Send + 'static + where Req: Serialize + Send + 'static, + Resp: Deserialize + Send + 'static, + E: Deserialize + Send + 'static { type ConnectFut = ConnectFuture; diff --git a/src/sync/client.rs b/src/sync/client.rs index f56467b..4b84488 100644 --- a/src/sync/client.rs +++ b/src/sync/client.rs @@ -36,9 +36,9 @@ impl fmt::Debug for Client { } impl Client - where Req: Serialize + Sync + Send + 'static, - Resp: Deserialize + Sync + Send + 'static, - E: Deserialize + Sync + Send + 'static + where Req: Serialize + Send + 'static, + Resp: Deserialize + Send + 'static, + E: Deserialize + Send + 'static { /// Drives an RPC call for the given request. pub fn call(&self, request: Req) -> Result> { @@ -128,9 +128,9 @@ pub trait ClientExt: Sized { } impl ClientExt for Client - where Req: Serialize + Sync + Send + 'static, - Resp: Deserialize + Sync + Send + 'static, - E: Deserialize + Sync + Send + 'static + where Req: Serialize + Send + 'static, + Resp: Deserialize + Send + 'static, + E: Deserialize + Send + 'static { fn connect(addr: A, options: Options) -> io::Result where A: ToSocketAddrs @@ -160,9 +160,9 @@ struct RequestHandler { } impl RequestHandler> - where Req: Serialize + Sync + Send + 'static, - Resp: Deserialize + Sync + Send + 'static, - E: Deserialize + Sync + Send + 'static + where Req: Serialize + Send + 'static, + Resp: Deserialize + Send + 'static, + E: Deserialize + Send + 'static { /// Creates a new `RequestHandler` by connecting a `FutureClient` to the given address /// using the given options.