Skip to content

doc-comments inside of macros broken #23812

Closed
@pyfisch

Description

@pyfisch
    foobar!{
        /// This is a doc comment
        (do) => (Some<Thing>)*
    }

#17830 enabled doc comments inside of macros, the doc comment in the example should be expanded to #[doc="This is a doc comment"] but the leading slashes are included. They are present in the output generated by rustdoc:

/// Accept header, defined in RFC7231 /// /// The Accept header field can be used by user agents to specify /// response media types that are acceptable. Accept header fields can /// be used to indicate that the request is specifically limited to a /// small set of desired types, as in the case of a request for an /// in-line image /// /// # ABNF /// plain /// Accept = #( media-range [ accept-params ] ) /// " /// media-range = ( "*/*"" /// / ( type "/" "*" )" /// / ( type "/" subtype )" /// ) *( OWS ";" OWS parameter )" /// accept-params = weight *( accept-ext )" /// accept-ext = OWS ";" OWS token [ "=" ( token / quoted-string ) ]" ///"

Version: rustc 1.0.0-nightly (199bdcfef 2015-03-26) (built 2015-03-27)

Metadata

Metadata

Assignees

Labels

A-macrosArea: All kinds of macros (custom derive, macro_rules!, proc macros, ..)T-rustdocRelevant to the rustdoc team, which will review and decide on the PR/issue.

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions