Cargo fmt

This commit is contained in:
Tim Kuehn
2017-01-22 20:01:22 -08:00
parent 45fa4c7bf1
commit 3196fd91ff
5 changed files with 16 additions and 18 deletions

View File

@@ -112,6 +112,7 @@ impl Options {
/// Exposes a trait for connecting asynchronously to servers.
pub mod future {
use super::{Client, Options};
use {REMOTE, Reactor};
use futures::{self, Async, Future, future};
use protocol::Proto;
@@ -119,7 +120,6 @@ pub mod future {
use std::io;
use std::marker::PhantomData;
use std::net::SocketAddr;
use super::{Client, Options};
use tokio_core::{self, reactor};
use tokio_core::net::TcpStream;
use tokio_proto::BindClient;
@@ -231,12 +231,12 @@ pub mod future {
/// Exposes a trait for connecting synchronously to servers.
pub mod sync {
use super::{Client, Options};
use client::future::Connect as FutureConnect;
use futures::{Future, future};
use serde::{Deserialize, Serialize};
use std::io;
use std::net::ToSocketAddrs;
use super::{Client, Options};
use util::FirstSocketAddr;
/// Types that can connect to a server synchronously.

View File

@@ -706,10 +706,10 @@ mod functional_test {
}
mod sync {
use {client, server};
use client::sync::Connect;
use super::{SyncClient, SyncService, SyncServiceExt};
use super::env_logger;
use {client, server};
use client::sync::Connect;
use util::FirstSocketAddr;
use util::Never;
@@ -753,11 +753,11 @@ mod functional_test {
}
mod future {
use super::{FutureClient, FutureService, FutureServiceExt};
use super::env_logger;
use {client, server};
use client::future::Connect;
use futures::{Finished, Future, finished};
use super::{FutureClient, FutureService, FutureServiceExt};
use super::env_logger;
use util::FirstSocketAddr;
use util::Never;

View File

@@ -75,9 +75,9 @@ pub fn listen<S, Req, Resp, E>(new_service: S, addr: SocketAddr, options: Option
/// Spawns a service that binds to the given address using the given handle.
fn listen_with<S, Req, Resp, E>(new_service: S,
addr: SocketAddr,
handle: Handle)
-> io::Result<SocketAddr>
addr: SocketAddr,
handle: Handle)
-> io::Result<SocketAddr>
where S: NewService<Request = Result<Req, DeserializeError>,
Response = Response<Resp, E>,
Error = io::Error> + Send + 'static,