Currently formatted code (clang-format 21.1.8):
int main() {
typename[:^^int:] i = 42;
typename int i = 42;
}
Expected:
int main() {
typename [:^^int:] i = 42;
typename int i = 42;
}
Splicer [: :] is not recognized and no space is added after typename.
It seems reasonable to have the same formatting whether the type is spellt out explicitly or it comes from a splicer.
Currently formatted code (clang-format 21.1.8):
Expected:
Splicer
[::]is not recognized and no space is added aftertypename.It seems reasonable to have the same formatting whether the type is spellt out explicitly or it comes from a splicer.