[clang-format] Handle unions like structs and classes
authorBjörn Schäpers <bjoern@hazardy.de>
Tue, 11 Oct 2022 07:04:28 +0000 (09:04 +0200)
committerBjörn Schäpers <bjoern@hazardy.de>
Mon, 24 Oct 2022 19:28:12 +0000 (21:28 +0200)
commitc5755f44f0cfcd90aa130497eb114f94182ebc69
tree4fb7c70957d898f82bc83d17ee5a1fb7135647c5
parent11b8795bb94c3606d8eed6f45bc3e4fbb0683c14
[clang-format] Handle unions like structs and classes

There is no reason why unions should be handled differently, I think
they are just forgotten since they are not used that often.

No test case added, since that would be complicated to produce.

Differential Revision: https://reviews.llvm.org/D135872
clang/lib/Format/TokenAnnotator.cpp