diff --git a/src/header/mod.rs b/src/header/mod.rs index a42ec1cc..3db36381 100644 --- a/src/header/mod.rs +++ b/src/header/mod.rs @@ -6,7 +6,7 @@ //! are already provided, such as `Host`, `ContentType`, `UserAgent`, and others. use std::any::Any; use std::ascii::{AsciiExt, AsciiCast}; -use std::borrow::{Borrowed, Owned}; +use std::borrow::Cow::{Borrowed, Owned}; use std::fmt::{mod, Show}; use std::intrinsics::TypeId; use std::raw::TraitObject; diff --git a/src/http.rs b/src/http.rs index 30313b40..1a255927 100644 --- a/src/http.rs +++ b/src/http.rs @@ -1,5 +1,5 @@ //! Pieces pertaining to the HTTP message protocol. -use std::borrow::{Borrowed, Owned}; +use std::borrow::Cow::{Borrowed, Owned}; use std::cmp::min; use std::fmt; use std::io::{mod, Reader, IoResult, BufWriter}; diff --git a/src/net.rs b/src/net.rs index 5d5771f4..63a4a7bc 100644 --- a/src/net.rs +++ b/src/net.rs @@ -12,7 +12,8 @@ use std::raw::{mod, TraitObject}; use std::sync::{Arc, Mutex}; use uany::UncheckedBoxAnyDowncast; -use openssl::ssl::{SslStream, SslContext, Sslv23}; +use openssl::ssl::{SslStream, SslContext}; +use openssl::ssl::SslMethod::Sslv23; use openssl::ssl::error::{SslError, StreamError, OpenSslErrors, SslSessionClosed}; use self::HttpStream::{Http, Https}; @@ -103,7 +104,7 @@ impl UncheckedBoxAnyDowncast for Box { } } -impl<'a> AnyRefExt<'a> for &'a NetworkStream + 'a { +impl<'a> AnyRefExt<'a> for &'a (NetworkStream + 'a) { #[inline] fn is(self) -> bool { self.get_type_id() == TypeId::of::() diff --git a/src/server/request.rs b/src/server/request.rs index a09a4169..303afd66 100644 --- a/src/server/request.rs +++ b/src/server/request.rs @@ -15,7 +15,7 @@ use http::HttpReader; use http::HttpReader::{SizedReader, ChunkedReader, EmptyReader}; use uri::RequestUri; -pub type InternalReader<'a> = &'a mut Reader + 'a; +pub type InternalReader<'a> = &'a mut (Reader + 'a); /// A request bundles several parts of an incoming `NetworkStream`, given to a `Handler`. pub struct Request<'a> { diff --git a/src/server/response.rs b/src/server/response.rs index f9d8992f..fe80be2f 100644 --- a/src/server/response.rs +++ b/src/server/response.rs @@ -14,7 +14,7 @@ use status; use net::{Fresh, Streaming}; use version; -pub type InternalWriter<'a> = &'a mut Writer + 'a; +pub type InternalWriter<'a> = &'a mut (Writer + 'a); /// The outgoing half for a Tcp connection, created by a `Server` and given to a `Handler`. pub struct Response<'a, W = Fresh> {