diff --git a/src/header/mod.rs b/src/header/mod.rs index b7cee39735..b846a568d9 100644 --- a/src/header/mod.rs +++ b/src/header/mod.rs @@ -9,11 +9,10 @@ use std::borrow::Cow::{Borrowed, Owned}; use std::fmt; use std::raw::TraitObject; use std::str::from_utf8; -use std::string::CowString; use std::collections::HashMap; use std::collections::hash_map::{Iter, Entry}; use std::iter::{FromIterator, IntoIterator}; -use std::borrow::IntoCow; +use std::borrow::{Cow, IntoCow}; use std::{mem, raw}; use uany::{UnsafeAnyExt}; @@ -30,7 +29,7 @@ mod common; mod shared; pub mod parsing; -type HeaderName = UniCase>; +type HeaderName = UniCase>; /// A trait for any object that will represent a header field and value. /// diff --git a/src/http.rs b/src/http.rs index f191dd7dba..7affb8bd92 100644 --- a/src/http.rs +++ b/src/http.rs @@ -1,11 +1,10 @@ //! Pieces pertaining to the HTTP message protocol. -use std::borrow::Cow::{Borrowed, Owned}; +use std::borrow::Cow::{self, Borrowed, Owned}; use std::borrow::IntoCow; use std::cmp::min; use std::old_io::{self, Reader, IoResult, BufWriter}; use std::num::from_u16; use std::str; -use std::string::CowString; use url::Url; use url::ParseError as UrlError; @@ -587,7 +586,7 @@ pub type StatusLine = (HttpVersion, RawStatus); /// The raw status code and reason-phrase. #[derive(PartialEq, Debug)] -pub struct RawStatus(pub u16, pub CowString<'static>); +pub struct RawStatus(pub u16, pub Cow<'static, str>); impl Clone for RawStatus { fn clone(&self) -> RawStatus {