diff --git a/src/header/map.rs b/src/header/map.rs index a668b311..7610175b 100644 --- a/src/header/map.rs +++ b/src/header/map.rs @@ -2020,7 +2020,7 @@ impl FromIterator<(HeaderName, T)> for HeaderMap { /// let headers: HeaderMap = (&map).try_into().expect("valid headers"); /// assert_eq!(headers["X-Custom-Header"], "my value"); /// ``` -impl<'a, K, V, T> TryFrom<&'a HashMap> for HeaderMap +impl<'a, K, V, S, T> TryFrom<&'a HashMap> for HeaderMap where K: Eq + Hash, HeaderName: TryFrom<&'a K>, @@ -2030,7 +2030,7 @@ where { type Error = Error; - fn try_from(c: &'a HashMap) -> Result { + fn try_from(c: &'a HashMap) -> Result { c.iter() .map(|(k, v)| -> crate::Result<(HeaderName, T)> { let name = TryFrom::try_from(k).map_err(Into::into)?;