Skip to content

Commit

Permalink
Update .clang-format file & apply clang-format to whole project
Browse files Browse the repository at this point in the history
  • Loading branch information
piponazo committed Mar 16, 2022
1 parent 8c5bf75 commit d0fd396
Show file tree
Hide file tree
Showing 207 changed files with 73,698 additions and 78,350 deletions.
23 changes: 1 addition & 22 deletions .clang-format
Original file line number Diff line number Diff line change
@@ -1,41 +1,20 @@
---
# Indentation for all files
ColumnLimit: 120
IndentWidth: 4
TabWidth: 4
UseTab: Never

# C++ Options
Language: Cpp
Standard: c++17

BasedOnStyle: Google

# Useful for sorting the project inclusions and standard library inclusions separately
IncludeBlocks: Preserve

AccessModifierOffset: -4
ContinuationIndentWidth: 4

# Constructor initializers better formatted in presence of preprocessor conditions (see image.cpp)
BreakConstructorInitializers: AfterColon
AllowAllConstructorInitializersOnNextLine: true

# break braces for most of the cases (except conditionals and loops)
BreakBeforeBraces: Custom
BraceWrapping:
AfterStruct: true
AfterClass: true
AfterFunction: true
AfterControlStatement: false
AfterEnum: true
AfterNamespace: true

# Do not allow SingleLine statements (to improve coverage statistics)
AllowShortFunctionsOnASingleLine: None
AllowShortBlocksOnASingleLine: false
AllowShortIfStatementsOnASingleLine: false
AllowShortLoopsOnASingleLine: false

Cpp11BracedListStyle: true

...
Loading

0 comments on commit d0fd396

Please sign in to comment.