Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit a78d9a29 authored by Christopher Ferris's avatar Christopher Ferris
Browse files

Add a 2 width option of clang format.

Make the default the 4 tab space version.

Add a link to the 2 space version for libbacktrace.

The only other difference between the 4 space and 2 space tab version
is that the 2 space tab version allows short functions on a single line.
This is for things like constructors, short destructors, or accessor
functions. I believe this is closer to the Google C++ style guide.

Bug: 36046320

Test: NA
Change-Id: Ida08db18902eeb101f42869dd5590182529d54ef
parent ce7ee088
Loading
Loading
Loading
Loading

.clang-format

deleted100644 → 0
+1 −13
Original line number Original line Diff line number Diff line
BasedOnStyle: Google
AllowShortBlocksOnASingleLine: false
AllowShortFunctionsOnASingleLine: false

AccessModifierOffset: -2
ColumnLimit: 100
CommentPragmas: NOLINT:.*
DerivePointerAlignment: false
IndentWidth: 4
PointerAlignment: Left
TabWidth: 4
UseTab: Never
PenaltyExcessCharacter: 32

.clang-format

0 → 120000
+1 −13
Original line number Original line Diff line number Diff line
.clang-format-4
 No newline at end of file

.clang-format-2

0 → 100644
+13 −0
Original line number Original line Diff line number Diff line
BasedOnStyle: Google
AllowShortBlocksOnASingleLine: false
AllowShortFunctionsOnASingleLine: true

AccessModifierOffset: -1
ColumnLimit: 100
CommentPragmas: NOLINT:.*
DerivePointerAlignment: false
IndentWidth: 2
PointerAlignment: Left
TabWidth: 2
UseTab: Never
PenaltyExcessCharacter: 32

.clang-format-4

0 → 100644
+13 −0
Original line number Original line Diff line number Diff line
BasedOnStyle: Google
AllowShortBlocksOnASingleLine: false
AllowShortFunctionsOnASingleLine: false

AccessModifierOffset: -2
ColumnLimit: 100
CommentPragmas: NOLINT:.*
DerivePointerAlignment: false
IndentWidth: 4
PointerAlignment: Left
TabWidth: 4
UseTab: Never
PenaltyExcessCharacter: 32
+1 −0
Original line number Original line Diff line number Diff line
../.clang-format-2
 No newline at end of file

.clang-format

100644 → 120000
+1 −13

File changed.File mode changed from 100644 to 120000.

Contains only whitespace changes.