style(headers): use regular doc-comments inside macros

A bug (rust-lang/rust#23812) in rustc prevented the use of normal
comments inside macros but this has been fixed.
This commit is contained in:
Pyfisch
2015-10-27 19:19:05 +01:00
parent d16ef6d9d4
commit 4c756a9304
33 changed files with 1209 additions and 1209 deletions

View File

@@ -1,43 +1,43 @@
use header::Encoding;
header! {
#[doc="`Content-Encoding` header, defined in"]
#[doc="[RFC7231](http://tools.ietf.org/html/rfc7231#section-3.1.2.2)"]
#[doc=""]
#[doc="The `Content-Encoding` header field indicates what content codings"]
#[doc="have been applied to the representation, beyond those inherent in the"]
#[doc="media type, and thus what decoding mechanisms have to be applied in"]
#[doc="order to obtain data in the media type referenced by the Content-Type"]
#[doc="header field. Content-Encoding is primarily used to allow a"]
#[doc="representation's data to be compressed without losing the identity of"]
#[doc="its underlying media type."]
#[doc=""]
#[doc="# ABNF"]
#[doc="```plain"]
#[doc="Content-Encoding = 1#content-coding"]
#[doc="```"]
#[doc=""]
#[doc="# Example values"]
#[doc="* `gzip`"]
#[doc=""]
#[doc="# Examples"]
#[doc="```"]
#[doc="use hyper::header::{Headers, ContentEncoding, Encoding};"]
#[doc=""]
#[doc="let mut headers = Headers::new();"]
#[doc="headers.set(ContentEncoding(vec![Encoding::Chunked]));"]
#[doc="```"]
#[doc="```"]
#[doc="use hyper::header::{Headers, ContentEncoding, Encoding};"]
#[doc=""]
#[doc="let mut headers = Headers::new();"]
#[doc="headers.set("]
#[doc=" ContentEncoding(vec!["]
#[doc=" Encoding::Gzip,"]
#[doc=" Encoding::Chunked,"]
#[doc=" ])"]
#[doc=");"]
#[doc="```"]
/// `Content-Encoding` header, defined in
/// [RFC7231](http://tools.ietf.org/html/rfc7231#section-3.1.2.2)
///
/// The `Content-Encoding` header field indicates what content codings
/// have been applied to the representation, beyond those inherent in the
/// media type, and thus what decoding mechanisms have to be applied in
/// order to obtain data in the media type referenced by the Content-Type
/// header field. Content-Encoding is primarily used to allow a
/// representation's data to be compressed without losing the identity of
/// its underlying media type.
///
/// # ABNF
/// ```plain
/// Content-Encoding = 1#content-coding
/// ```
///
/// # Example values
/// * `gzip`
///
/// # Examples
/// ```
/// use hyper::header::{Headers, ContentEncoding, Encoding};
///
/// let mut headers = Headers::new();
/// headers.set(ContentEncoding(vec![Encoding::Chunked]));
/// ```
/// ```
/// use hyper::header::{Headers, ContentEncoding, Encoding};
///
/// let mut headers = Headers::new();
/// headers.set(
/// ContentEncoding(vec![
/// Encoding::Gzip,
/// Encoding::Chunked,
/// ])
/// );
/// ```
(ContentEncoding, "Content-Encoding") => (Encoding)+
test_content_encoding {