diff --git a/src/header/common/cache_control.rs b/src/header/common/cache_control.rs index df067ce700..997fdfd723 100644 --- a/src/header/common/cache_control.rs +++ b/src/header/common/cache_control.rs @@ -23,7 +23,7 @@ use header::parsing::{from_one_comma_delimited, fmt_comma_delimited}; #[derive(PartialEq, Clone, Debug)] pub struct CacheControl(pub Vec); -deref!(CacheControl => Vec); +__hyper__deref!(CacheControl => Vec); impl Header for CacheControl { fn header_name() -> &'static str { diff --git a/src/header/common/cookie.rs b/src/header/common/cookie.rs index f99527931e..5d279ae3e2 100644 --- a/src/header/common/cookie.rs +++ b/src/header/common/cookie.rs @@ -20,7 +20,7 @@ use cookie::CookieJar; #[derive(Clone, PartialEq, Debug)] pub struct Cookie(pub Vec); -deref!(Cookie => Vec); +__hyper__deref!(Cookie => Vec); impl Header for Cookie { fn header_name() -> &'static str { diff --git a/src/header/common/mod.rs b/src/header/common/mod.rs index feba590922..55b905970c 100644 --- a/src/header/common/mod.rs +++ b/src/header/common/mod.rs @@ -80,7 +80,7 @@ macro_rules! bench_header( ); #[macro_export] -macro_rules! deref( +macro_rules! __hyper__deref { ($from:ty => $to:ty) => { impl ::std::ops::Deref for $from { type Target = $to; @@ -96,7 +96,7 @@ macro_rules! deref( } } } -); +} #[macro_export] macro_rules! __hyper__tm { @@ -166,7 +166,7 @@ macro_rules! header { $(#[$a])* #[derive(Clone, Debug, PartialEq)] pub struct $id(pub Vec<$item>); - deref!($id => Vec<$item>); + __hyper__deref!($id => Vec<$item>); impl $crate::header::Header for $id { fn header_name() -> &'static str { $n @@ -192,7 +192,7 @@ macro_rules! header { $(#[$a])* #[derive(Clone, Debug, PartialEq)] pub struct $id(pub Vec<$item>); - deref!($id => Vec<$item>); + __hyper__deref!($id => Vec<$item>); impl $crate::header::Header for $id { fn header_name() -> &'static str { $n @@ -218,7 +218,7 @@ macro_rules! header { $(#[$a])* #[derive(Clone, Debug, PartialEq)] pub struct $id(pub $value); - deref!($id => $value); + __hyper__deref!($id => $value); impl $crate::header::Header for $id { fn header_name() -> &'static str { $n diff --git a/src/header/common/set_cookie.rs b/src/header/common/set_cookie.rs index 604f1b2a3a..2b3f3d27e8 100644 --- a/src/header/common/set_cookie.rs +++ b/src/header/common/set_cookie.rs @@ -57,7 +57,7 @@ use cookie::CookieJar; #[derive(Clone, PartialEq, Debug)] pub struct SetCookie(pub Vec); -deref!(SetCookie => Vec); +__hyper__deref!(SetCookie => Vec); impl Header for SetCookie { fn header_name() -> &'static str {