Skip to content

rustdoc breaking change in #84445 - # in line start is not stripped #84502

Closed
@SergioBenitez

Description

@SergioBenitez

Rocket has:

// This (long, contrived) form string...
# assert_form_parses! { Foo,
"[k:top_key][i][k:sub_key]name=Bobert&\
[k:top_key][i][k:sub_key]age=22&\
[k:top_key][i][sub_key]=1337&\
[top_key][7]name=Builder&\
[top_key][7]age=99",

// We could also set the top-level value's key explicitly:
// [top_key][k:7]=7
# "[k:top_key][i][k:sub_key]name=Bobert&\
# [k:top_key][i][k:sub_key]age=22&\
# [top_key][k:7]=7&\
# [k:top_key][i][sub_key]=1337&\
# [top_key][7]name=Builder&\
# [top_key][7]age=99",
# =>

Previously, the #s in the second string were stripped by rustdoc, and so the string passed to the macro did not contain the leading #s. Now, they are not stripped, and so a string with #s gets passed to the macro, causing the test to fail.

cc #84445, @GuillaumeGomez, @jyn514

@rustbot modify labels: +regression-from-stable-to-nightly

Metadata

Metadata

Assignees

No one assigned

    Labels

    T-rustdocRelevant to the rustdoc team, which will review and decide on the PR/issue.regression-from-stable-to-nightlyPerformance or correctness regression from stable to nightly.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions