We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent ed680c4 commit 221f644Copy full SHA for 221f644
1 file changed
src/header/value.rs
@@ -173,11 +173,12 @@ impl HeaderValue {
173
/// within the buffer.
174
///
175
/// ## Panics
176
- /// In a debug build this will panic if `src` is not valid UTF-8.
+ /// In a debug build this will panic if `src` contains bytes that are not
177
+ /// allowed in HTTP field values.
178
179
/// ## Safety
- /// `src` must contain valid UTF-8. In a release build it is undefined
180
- /// behaviour to call this with `src` that is not valid UTF-8.
+ /// `src` must contain valid HTTP field value. In a release build it is
181
+ /// undefined behaviour to call this with `src` that is not valid.
182
pub unsafe fn from_maybe_shared_unchecked<T>(src: T) -> HeaderValue
183
where
184
T: AsRef<[u8]> + 'static,
0 commit comments