Update .clang-format with more rules

This commit is contained in:
Sam Ellicott 2021-03-13 13:58:17 -05:00
parent b28c4d2c40
commit 472615bbf7

View file

@ -1,3 +1,4 @@
# Basic style rules by Charles Lohr
BasedOnStyle: Microsoft BasedOnStyle: Microsoft
AccessModifierOffset: -4 AccessModifierOffset: -4
AlwaysBreakTemplateDeclarations: 'Yes' AlwaysBreakTemplateDeclarations: 'Yes'
@ -21,4 +22,16 @@ SpacesInSquareBrackets: 'true'
TabWidth: '4' TabWidth: '4'
UseTab: Always UseTab: Always
FixNamespaceComments: 'true' FixNamespaceComments: 'true'
IndentCaseLabels: 'true' IndentCaseLabels: 'true'
# Additions by Sam Ellicott
ColumnLimit: 100
AlignConsecutiveAssignments: true
AlignConsecutiveMacros: true
AlignTrailingComments: true
AlignEscapedNewlines: Left
AlignOperands: AlignAfterOperator
AllowShortBlocksOnASingleLine: Always
AllowShortIfStatementsOnASingleLine: WithoutElse
AllowShortCaseLabelsOnASingleLine: true
AllowShortLoopsOnASingleLine: true