Skip to content

Commit

Permalink
Add .clang-format
Browse files Browse the repository at this point in the history
Signed-off-by: Ping Xie <[email protected]>
  • Loading branch information
PingXie committed May 13, 2024
1 parent f5024f6 commit fc8962d
Showing 1 changed file with 29 additions and 0 deletions.
29 changes: 29 additions & 0 deletions src/.clang-format
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
BasedOnStyle: LLVM
IndentWidth: 4
TabWidth: 4
UseTab: Never
ColumnLimit: 120
PenaltyBreakComment: 300
PenaltyBreakFirstLessLess: 120
PenaltyBreakString: 100
PenaltyExcessCharacter: 100
MaxEmptyLinesToKeep: 2
BreakBeforeBraces: Attach
AllowShortCaseLabelsOnASingleLine: true
AllowShortIfStatementsOnASingleLine: WithoutElse
AllowShortLoopsOnASingleLine: true
AllowShortFunctionsOnASingleLine: false
AlignConsecutiveAssignments: false
AlignConsecutiveDeclarations: false
AlignTrailingComments: true
PointerAlignment: Right
KeepEmptyLinesAtTheStartOfBlocks: false
SpaceBeforeParens: ControlStatements
SpacesInParentheses: false
SpacesInAngles: false
SpacesInCStyleCastParentheses: false
SpaceAfterCStyleCast: false
SpacesInSquareBrackets: false
ReflowComments: true
CommentPragmas: '^\\s*\\*'
SortIncludes: false

0 comments on commit fc8962d

Please sign in to comment.