Skip to content

Double Commas in #derive eats entire #derive #3898

Closed
@sanbox-irl

Description

@sanbox-irl

Input:

#[derive(Debug, ,Clone)]
pub enum Test {
    One,
    Two
}

(note the double commas after Debug above. The space is irrelevant in my testing)

Outputs:

#[derive()]
pub enum Test {
    One,
    Two,
}

and a :( from me.

Thanks guys

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugPanic, non-idempotency, invalid code, etc.good first issueIssues up for grabs, also good candidates for new rustfmt contributorsp-low

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions