Skip to content

With wrap_comments = true, rustfmt removes significant empty doc lines #5073

Open
@jplatte

Description

@jplatte

axum contains the following pattern (here):

//! Text
//!
#![doc = include_str!("something.md")]
//!
//! More text

With wrap_comments = true, rustfmt currently removes the //! line before the #![doc] attribute, merging two paragraphs if something.md also starts with regular text (not a heading or sth. like that).

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions