RFC: Add clang-format configuration and CONTRIBUTING.md#855
Open
lemenkov wants to merge 1 commit intoSIPp:masterfrom
Open
RFC: Add clang-format configuration and CONTRIBUTING.md#855lemenkov wants to merge 1 commit intoSIPp:masterfrom
lemenkov wants to merge 1 commit intoSIPp:masterfrom
Conversation
Add .clang-format with proposed code style for discussion: - 4-space indentation (no tabs) - Allman/BSD brace style - 120 character line limit - Pointer/reference aligned right (char *ptr) - Includes not sorted (to avoid breaking builds) Also add CONTRIBUTING.md with formatting instructions and editor integration tips. CI enforcement will be added after the team agrees on the style. Signed-off-by: Peter Lemenkov <lemenkov@gmail.com> Assisted-by: Claude (Anthropic) <https://claude.ai>
Contributor
|
Does the entire codebase conform to these format rules? Do we need another commit for "format everything"? |
Member
Author
No, not yet. So we do need a commit to enforce everything. We could do it gradually - every new PR will make us closer. |
orgads
approved these changes
Feb 18, 2026
orgads
reviewed
Feb 18, 2026
| NamespaceIndentation: None | ||
|
|
||
| # Braces - Allman/BSD style (braces on their own lines) | ||
| BreakBeforeBraces: Allman |
Contributor
There was a problem hiding this comment.
The code has both Allman and Linux. I generally prefer Linux actually (https://clang.llvm.org/docs/ClangFormatStyleOptions.html#breakbeforebraces)
orgads
requested changes
Feb 18, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Add .clang-format with proposed code style for discussion:
Also add CONTRIBUTING.md with formatting instructions and editor integration tips.
CI enforcement will be added after the team agrees on the style.