From 208720be531dfdd3b4513463245e4d936368abee Mon Sep 17 00:00:00 2001 From: David Pedersen Date: Tue, 25 Jan 2022 09:46:38 +0100 Subject: [PATCH] Clarity `Err` usage in `IntoResponseHeaders` --- axum-core/src/response/mod.rs | 2 ++ 1 file changed, 2 insertions(+) diff --git a/axum-core/src/response/mod.rs b/axum-core/src/response/mod.rs index 15f67577..166b301b 100644 --- a/axum-core/src/response/mod.rs +++ b/axum-core/src/response/mod.rs @@ -156,6 +156,8 @@ pub trait IntoResponseHeaders { type IntoIter: IntoIterator, HeaderValue), Response>>; /// Attempt to turn `self` into a list of headers. + /// + /// In practice, only the implementation for `axum::response::Headers` ever returns `Err(_)`. #[doc(hidden)] fn into_headers(self) -> Self::IntoIter; }