1 # Suricata settings as per
2 # doc/devguide/codebase/code-style.rst
4 # This file is set up for clang 9. For the settings available, see
5 # https://releases.llvm.org/9.0.0/tools/clang/docs/ClangFormatStyleOptions.html
7 # For the settings available in the latest clang release, see
8 # https://clang.llvm.org/docs/ClangFormatStyleOptions.html
11 AlignAfterOpenBracket: DontAlign
12 AlignConsecutiveMacros: true
13 AlignEscapedNewlines: Right
14 # clang 10: AllowShortBlocksOnASingleLine: Never
15 # clang 11: AllowShortEnumsOnASingleLine: false
16 AllowShortFunctionsOnASingleLine: None
17 # BreakBeforeBraces: Mozilla is closest, but does not split empty functions/structs
20 AfterControlStatement: false
25 AfterExternBlock: true
28 SplitEmptyFunction: true
29 SplitEmptyRecord: true
30 BreakBeforeBraces: Custom
31 Cpp11BracedListStyle: false
33 ConstructorInitializerIndentWidth: 8
34 ContinuationIndentWidth: 8
35 ForEachMacros: ['json_array_foreach', 'json_object_foreach', 'SLIST_FOREACH',
36 'SLIST_FOREACH_PREVPTR', 'LIST_FOREACH', 'SIMPLEQ_FOREACH', 'TAILQ_FOREACH',
37 'TAILQ_FOREACH_SAFE', 'TAILQ_FOREACH_REVERSE', 'CIRCLEQ_FOREACH',
38 'CIRCLEQ_FOREACH_REVERSE', 'CIRCLEQ_FOREACH_SAFE', 'CIRCLEQ_FOREACH_REVERSE_SAFE',
39 'SPLAY_FOREACH, RB_FOREACH', 'RB_FOREACH_FROM', 'RB_FOREACH_SAFE',
40 'RB_FOREACH_REVERSE', 'RB_FOREACH_REVERSE_FROM', 'RB_FOREACH_REVERSE_SAFE' ]
41 IndentCaseLabels: true
46 # implicit by LLVM style
47 #BreakBeforeTernaryOperators: true