Skip to content

rustfmt stopped formatting const items in macros #6035

@CAD97

Description

@CAD97

Test:

> echo "m!(const N: usize = 0;);" | rustup run beta rustfmt
m!(
    const N: usize = 0;
);

> echo "m!(const N: usize = 0;);" | rustup run nightly rustfmt
m!(const N: usize = 0;);

> rustup run beta rustfmt -Vv
rustfmt 1.7.0-beta (f732c37b417 2024-01-12)
> rustup run nightly rustfmt -Vv
rustfmt 1.7.0-nightly (88189a71 2024-01-19)

Metadata

Metadata

Assignees

No one assigned

    Labels

    A-macrosArea: macros (procedural macros, macro_rules! macros, etc.)C-bugCategory: this is a bug; use also I-* labels for specific bug kinds, e.g. I-non-idempotency or I-ICE

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions