Elyes Haouas has uploaded this change for review. ( https://review.coreboot.org/c/coreboot/+/86023?usp=email )
Change subject: clang-format: Update to 16.0.6 and later ......................................................................
clang-format: Update to 16.0.6 and later
Change-Id: Ib3856f858501e43c4cb33057a0d2b62b1d2bb7b0 Signed-off-by: Elyes Haouas ehaouas@noos.fr --- M .clang-format 1 file changed, 77 insertions(+), 84 deletions(-)
git pull ssh://review.coreboot.org:29418/coreboot refs/changes/23/86023/1
diff --git a/.clang-format b/.clang-format index 47210ae..fd38f5b 100644 --- a/.clang-format +++ b/.clang-format @@ -1,6 +1,6 @@ # SPDX-License-Identifier: GPL-2.0-only # -# clang-format configuration file. Intended for clang-format >= 16. +# clang-format configuration file. Intended for clang-format >= 16.0.6 # # For more information, see: # @@ -8,41 +8,41 @@ # https://clang.llvm.org/docs/ClangFormatStyleOptions.html # https://clang-format-configurator.site/ # - --- -Language: Cpp +BasedOnStyle: InheritParentConfig +Language: Cpp AccessModifierOffset: -4 AlignAfterOpenBracket: Align AlignArrayOfStructures: Left AlignConsecutiveAssignments: - Enabled: false + Enabled: false AcrossEmptyLines: false - AcrossComments: true - AlignCompound: false - PadOperators: true + AcrossComments: true + AlignCompound: false + PadOperators: true AlignConsecutiveBitFields: - Enabled: true + Enabled: true AcrossEmptyLines: false - AcrossComments: false - AlignCompound: false - PadOperators: true + AcrossComments: false + AlignCompound: false + PadOperators: true AlignConsecutiveDeclarations: - Enabled: false + Enabled: false AcrossEmptyLines: false - AcrossComments: false - AlignCompound: false - PadOperators: true + AcrossComments: false + AlignCompound: false + PadOperators: true AlignConsecutiveMacros: - Enabled: true + Enabled: true AcrossEmptyLines: false - AcrossComments: false - AlignCompound: false - PadOperators: true + AcrossComments: false + AlignCompound: false + PadOperators: true AlignEscapedNewlines: Left -AlignOperands: Align +AlignOperands: Align AlignTrailingComments: - Kind: Always - OverEmptyLines: 0 + Kind: Always + OverEmptyLines: 0 AllowAllArgumentsOnNextLine: true AllowAllParametersOfDeclarationOnNextLine: false AllowShortBlocksOnASingleLine: Never @@ -52,50 +52,47 @@ AllowShortIfStatementsOnASingleLine: Never AllowShortLambdasOnASingleLine: All AllowShortLoopsOnASingleLine: false -AlwaysBreakAfterDefinitionReturnType: None AlwaysBreakAfterReturnType: None AlwaysBreakBeforeMultilineStrings: false AlwaysBreakTemplateDeclarations: MultiLine - -# git grep '^#define [^[:space:]]*__.*[^[:space:]]*__attribute__' | grep -v "vendorcode|payloads|util" | sed "s|.*:||;s|^#define ([^[:space:]]*__[^([:space:]]*).*$| - '\1'|" | LC_ALL=C sort -u AttributeMacros: - - '__aligned' - - '__always_inline' - - '__always_unused' - - '__cpu_driver' - - '__fallthrough' - - '__maybe_unused' - - '__must_check' - - '__noreturn' - - '__packed' - - '__pci_driver' - - '__printf' - - '__weak' + - __aligned + - __always_inline + - __always_unused + - __cpu_driver + - __fallthrough + - __maybe_unused + - __must_check + - __noreturn + - __packed + - __pci_driver + - __printf + - __weak BinPackArguments: true BinPackParameters: true BitFieldColonSpacing: Both BraceWrapping: - AfterCaseLabel: false - AfterClass: false + AfterCaseLabel: false + AfterClass: false AfterControlStatement: Never - AfterEnum: false + AfterEnum: false AfterExternBlock: false - AfterFunction: true - AfterNamespace: true + AfterFunction: true + AfterNamespace: true AfterObjCDeclaration: false - AfterStruct: false - AfterUnion: false - BeforeCatch: false - BeforeElse: false + AfterStruct: false + AfterUnion: false + BeforeCatch: false + BeforeElse: false BeforeLambdaBody: false - BeforeWhile: false - IndentBraces: false + BeforeWhile: false + IndentBraces: false SplitEmptyFunction: true SplitEmptyRecord: true SplitEmptyNamespace: true BreakAfterAttributes: Never BreakAfterJavaFieldAnnotations: false -BreakArrays: false +BreakArrays: false BreakBeforeBinaryOperators: None BreakBeforeConceptDeclarations: Always BreakBeforeBraces: Custom @@ -104,31 +101,27 @@ BreakConstructorInitializers: AfterColon BreakInheritanceList: AfterColon BreakStringLiterals: false -ColumnLimit: 96 -CommentPragmas: '^ IWYU pragma:' +ColumnLimit: 96 +CommentPragmas: "^ IWYU pragma:" CompactNamespaces: false ConstructorInitializerIndentWidth: 8 ContinuationIndentWidth: 8 Cpp11BracedListStyle: true DerivePointerAlignment: false -DisableFormat: false +DisableFormat: false EmptyLineAfterAccessModifier: Never EmptyLineBeforeAccessModifier: LogicalBlock ExperimentalAutoDetectBinPacking: false FixNamespaceComments: false - -# git grep '^#define [^[:space:]]*for_each[^[:space:]]*(' | grep -v "vendorcode|payloads|util" | sed "s|.*:||;s|^#define ([^[:space:]]*for_each[^[:space:]]*)(.*$| - '\1'|" | LC_ALL=C sort -u ForEachMacros: - - 'list_for_each' - -# git grep -i '^#define +if[^[:space:]]*(' | grep -v "vendorcode|payloads|util" | sed "s|.*:||;s|^#define ([^[:space:]]*if[^[:space:]]*)(.*$| - '\1'|I" | grep -v IFIX | LC_ALL=C sort -u + - list_for_each IfMacros: - - 'IF_CHANNEL_POPULATED' - - 'IF_DIMM_POPULATED' - - 'IF_RANK_POPULATED' - - 'IfBit0' -IncludeBlocks: Preserve -IncludeIsMainSourceRegex: '' + - IF_CHANNEL_POPULATED + - IF_DIMM_POPULATED + - IF_RANK_POPULATED + - IfBit0 +IncludeBlocks: Preserve +IncludeIsMainSourceRegex: "" IndentAccessModifiers: false IndentCaseBlocks: false IndentCaseLabels: false @@ -136,25 +129,25 @@ IndentGotoLabels: false IndentPPDirectives: None IndentRequiresClause: true -IndentWidth: 8 +IndentWidth: 8 IndentWrappedFunctionNames: false -InsertBraces: false +InsertBraces: false InsertNewlineAtEOF: true InsertTrailingCommas: None IntegerLiteralSeparator: - Binary: 0 + Binary: 0 BinaryMinDigits: 0 - Decimal: 0 + Decimal: 0 DecimalMinDigits: 0 - Hex: 0 - HexMinDigits: 0 + Hex: 0 + HexMinDigits: 0 JavaScriptQuotes: Leave JavaScriptWrapImports: true KeepEmptyLinesAtTheStartOfBlocks: false LambdaBodyIndentation: Signature -LineEnding: LF -MacroBlockBegin: '' -MacroBlockEnd: '' +LineEnding: LF +MacroBlockBegin: "" +MacroBlockEnd: "" MaxEmptyLinesToKeep: 1 NamespaceIndentation: None ObjCBinPackProtocolList: Auto @@ -174,17 +167,17 @@ PenaltyIndentedWhitespace: 0 PenaltyReturnTypeOnItsOwnLine: 60 PointerAlignment: Right -PPIndentWidth: -1 +PPIndentWidth: -1 QualifierAlignment: Left ReferenceAlignment: Pointer -ReflowComments: false +ReflowComments: false RemoveBracesLLVM: false RemoveSemicolon: false RequiresClausePosition: OwnLine RequiresExpressionIndentation: OuterScope SeparateDefinitionBlocks: Leave ShortNamespaceLines: 1 -SortIncludes: Never +SortIncludes: Never SortJavaStaticImport: Before SortUsingDeclarations: Never SpaceAfterCStyleCast: false @@ -202,7 +195,7 @@ AfterForeachMacros: false AfterFunctionDefinitionName: false AfterFunctionDeclarationName: false - AfterIfMacros: false + AfterIfMacros: false AfterOverloadedOperator: false AfterRequiresInClause: false AfterRequiresInExpression: false @@ -212,17 +205,17 @@ SpaceInEmptyBlock: false SpaceInEmptyParentheses: false SpacesBeforeTrailingComments: 1 -SpacesInAngles: Never +SpacesInAngles: Never SpacesInConditionalStatement: false SpacesInContainerLiterals: false SpacesInCStyleCastParentheses: false SpacesInLineCommentPrefix: - Minimum: 1 - Maximum: 1 + Minimum: 1 + Maximum: 1 SpacesInParentheses: false SpacesInSquareBrackets: false -Standard: c++17 -TabWidth: 8 -UseTab: ForContinuationAndIndentation -... - +Standard: Latest +TabWidth: 8 +UseTab: ForContinuationAndIndentation +IncludeIsMainRegex: "" +---