Skip to content

clang-format does not handle semicolons in template argument lists #46505

Closed
@JohelEGP

Description

@JohelEGP
Bugzilla Link 47161
Version trunk
OS Linux
CC @JohelEGP,@mydeveloperday

Extended Description

This is how semicolons in template argument lists are formatted with the default configuration:

template <auto> struct X {};

struct Y : X < [] {
  return 0;
} > {};

struct Z : X < decltype([]
{
  return 0;
}){} > {};

struct W : X < requires {
  ill - formed;
} > {};

These uses will become more common in C++20 thanks to the used features.

Metadata

Metadata

Labels

bugIndicates an unexpected problem or unintended behaviorbugzillaIssues migrated from bugzillaclang-format

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions