refactor(headers): Improve docs, fix nits, make formatting faster
src/header/parsing.rs now uses unsafe get_unchecked() again, I don't know why it was removed.
This commit is contained in:
		| @@ -42,10 +42,10 @@ impl Header for Pragma { | ||||
|  | ||||
| impl HeaderFormat for Pragma { | ||||
|     fn fmt_header(&self, f: &mut fmt::Formatter) -> fmt::Result { | ||||
|         match *self { | ||||
|             Pragma::NoCache => write!(f, "no-cache"), | ||||
|             Pragma::Ext(ref string) => write!(f, "{}", string), | ||||
|         } | ||||
|         f.write_str(match *self { | ||||
|             Pragma::NoCache => "no-cache", | ||||
|             Pragma::Ext(ref string) => &string[..], | ||||
|         }) | ||||
|     } | ||||
| } | ||||
|  | ||||
|   | ||||
		Reference in New Issue
	
	Block a user