Skip to content

[clang-format] Incorrect formatting of requires expressions inside brace initialization #162984

@TheAliceBaskerville

Description

@TheAliceBaskerville

clang-format version: 22.0.0git

Reproducer:

clang-format --style=LLVM test.cpp

test.cpp:

bool foo{requires {0;}};

clang-format output:

bool foo{requires {0;
}
}
;

Expected behavior:

bool foo{requires {0;}};

Environment:

clang-format version 22.0.0git (https://github.com/llvm/llvm-project.git 779868de6975f6fd0ea17bb9a8e929037d3752d7)
Windows 10 (22H2) 19045.6332

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions