Skip to content

rustfmt fails to format a lambda in a method call with a large tuple pattern #6745

@programmerjake

Description

@programmerjake

https://play.rust-lang.org/?version=stable&mode=debug&edition=2024&gist=a8bacd11957fe7bcbc35ed7f9f667f73
I reduced the failure to:

fn f() {
    v.f(
        (),
        |(cd,to_fetch,from_decode,post_decode_output,from_retire,state_for_debug), mut sim| async {
            todo!();
        },
    );
}

I tested it with both 1.8.0-stable (2025-11-07 ed61e7d7e2) and 1.8.0-nightly (2025-12-08 37aa2135b5)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions