Skip to content

Commit

Permalink
editorconfig: Add C++ indentation style
Browse files Browse the repository at this point in the history
This commit adds the indentation style for the C++ source and header
files.

Note that the C++ indentation style has been configured to match that
of the C files because the C++ source files we currently have in the
Zephyr repository follow the style we enforce for the C files.

In the future, it may be preferable to follow the indentation style
recommended by one of the common C++ style guides, such as the Google
C++ Style Guide which recommends 2 spaces for indentation.

Signed-off-by: Stephanos Ioannidis <[email protected]>
  • Loading branch information
stephanosio authored and nashif committed Apr 28, 2022
1 parent ef9c4f7 commit 3a7cf87
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions .editorconfig
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,11 @@ indent_size = 8
indent_style = tab
indent_size = 8

# C++
[*.{cpp,hpp}]
indent_style = tab
indent_size = 8

# Linker Script
[*.ld]
indent_style = tab
Expand Down

0 comments on commit 3a7cf87

Please sign in to comment.