Update .clang-format

This commit is contained in:
souldbminersmwc
2026-06-04 19:29:31 -04:00
parent 82ce031851
commit 06ec789e32

View File

@@ -7,28 +7,40 @@ BasedOnStyle: LLVM
IndentWidth: 4 IndentWidth: 4
UseTab: Never UseTab: Never
BreakBeforeBraces: Linux # === Struct/Union/Class member indentation ===
# These options control indentation of struct members to ensure consistent
# 4-space indentation for all struct/union/class members
IndentAccessModifiers: false
AccessModifierOffset: 0
NamespaceIndentation: All
BreakBeforeBraces: Attach
BraceWrapping: BraceWrapping:
AfterControlStatement: false AfterControlStatement: false
AfterFunction: true AfterFunction: false
AfterClass: false AfterClass: false
AfterStruct: false AfterStruct: false
# AfterStruct: false keeps struct opening brace on same line (K&R style)
# Struct members will still be indented with IndentWidth: 4
AfterUnion: false AfterUnion: false
AfterNamespace: false AfterNamespace: false
AfterEnum: false AfterEnum: false
BeforeCatch: false BeforeCatch: false
BeforeElse: false BeforeElse: false
IndentBraces: false IndentBraces: false
# IndentBraces: false ensures braces themselves are not indented,
# but content inside braces respects IndentWidth setting
ContinuationIndentWidth: 0
AlignAfterOpenBracket: false
AllowShortIfStatementsOnASingleLine: false AllowShortIfStatementsOnASingleLine: false
AllowShortLoopsOnASingleLine: false AllowShortLoopsOnASingleLine: false
AllowShortBlocksOnASingleLine: Always AllowShortBlocksOnASingleLine: Always
# AllowShortFunctionsOnASingleLine: None enforces function bodies
# to always be on separate lines, following K&R convention
AllowShortFunctionsOnASingleLine: None
IndentCaseLabels: false IndentCaseLabels: false
SpaceAfterCStyleCast: true SpaceAfterCStyleCast: true
AllowShortFunctionsOnASingleLine: None ColumnLimit: 150
ColumnLimit: 80
MaxEmptyLinesToKeep: 1 MaxEmptyLinesToKeep: 1
Cpp11BracedListStyle: false Cpp11BracedListStyle: false
AlignTrailingComments: true AlignTrailingComments: true
@@ -39,7 +51,9 @@ IncludeBlocks: Regroup
IncludeCategories: IncludeCategories:
- Regex: '<[[:alnum:].]+>' - Regex: '<[[:alnum:].]+>'
Priority: 1 Priority: 1
# System headers (angle brackets) have highest priority
- Regex: '.*' - Regex: '.*'
Priority: 2 Priority: 2
# Project headers (quotes) have lower priority
SortIncludes: CaseSensitive SortIncludes: CaseSensitive
AlignEscapedNewlines: Left AlignEscapedNewlines: Left