Closed FintasticMan closed 1 year ago
Turns out, not all options that apply to this codebase from clang-format 12 have been added to the configuration, EmptyLineBeforeAccessModifier: LogicalBlock
and SpaceBeforeCaseColon: false
were missed. They don't affect existing code.
Now that the GH Actions VMs have updated to Ubuntu 22.04, clang can be updated to 14 over 12. I've looked through all the clang-format options that have been added in 13 and 14, and added the ones I believe fit our coding style. These options are:
EmptyLineAfterAccessModifier: Never
,IndentAccessModifiers: false
,PackConstructorInitializers: NextLine
,ReferenceAlignment: Pointer
andSeparateDefinitionBlocks: Always
. All of these except the last one don't actually change the formatting at all, just prevent any incorrect formatting in the future. The last one adds some new lines between definition blocks in some cases.This change fixes a compiler error in the clang-tidy check, about the
-fstack-usage
flag.