Skip to content

[clang-format] Unnecessary extra spaces around template brackets #110968

Closed
@carlosgalvezp

Description

@carlosgalvezp

When bumping from clang-format 18.1.8 to 19.1.1 we notice this change in formatting:

$ cat test.cpp
auto x = std::conditional_t<T::value == U::value, T, U>{};
$ clang-format-19 test.cpp
auto x = std::conditional_t < T::value == U::value, T, U > {};

Notice the extra spaces around the < and >. This happens with default configuration (no .clang-format file). This is also happening in main:
https://godbolt.org/z/9nv3js7qe

Metadata

Metadata

Assignees

Type

No type

Projects

Status

Done

Relationships

None yet

Development

No branches or pull requests

Issue actions