Skip to content

rustdoc generates playpen links with incorrect indentation #35483

Closed
@frewsxcv

Description

@frewsxcv

Steps to reproduce:

  1. https://doc.rust-lang.org/std/env/fn.args.html
  2. Click on "Run" in the example block

Playpen opens up with this code snippet:

fn main() {
    use std::env;

// Prints each argument on a separate line
for argument in env::args() {
    println!("{}", argument);
}
}

It should instead open up with this snippet:

fn main() {
    use std::env;

    // Prints each argument on a separate line
    for argument in env::args() {
        println!("{}", argument);
    }
}

Metadata

Metadata

Assignees

No one assigned

    Labels

    C-bugCategory: This is a bug.E-hardCall for participation: Hard difficulty. Experience needed to fix: A lot.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