clang-format revision 1.4 1 1.1 mrg # Copyright (C) 2015 Free Software Foundation, Inc.
2 1.1 mrg #
3 1.1 mrg # This program is free software; you can redistribute it and/or modify
4 1.1 mrg # it under the terms of the GNU General Public License as published by
5 1.1 mrg # the Free Software Foundation; either version 3 of the License, or
6 1.1 mrg # (at your option) any later version.
7 1.1 mrg #
8 1.1 mrg # This program is distributed in the hope that it will be useful,
9 1.1 mrg # but WITHOUT ANY WARRANTY; without even the implied warranty of
10 1.1 mrg # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
11 1.1 mrg # GNU General Public License for more details.
12 1.1 mrg #
13 1.1 mrg # You should have received a copy of the GNU General Public License
14 1.1 mrg # along with this program. If not, see <http://www.gnu.org/licenses/>.
15 1.1 mrg
16 1.4 mrg # clang-format 7.0.1 is required
17 1.1 mrg #
18 1.1 mrg # To utilize the tool to lines just touched by a patch, use
19 1.4 mrg # clang-format-diff script that is usually also packaged with clang-format.
20 1.4 mrg #
21 1.4 mrg # Example of usage:
22 1.4 mrg # git diff -U0 --no-color | clang-format-diff -p1
23 1.4 mrg # (here the tool will generate a patch)
24 1.4 mrg # git diff -U0 --no-color | clang-format-diff -p1 -i
25 1.4 mrg # (modifications are applied)
26 1.1 mrg
27 1.1 mrg ---
28 1.1 mrg Language: Cpp
29 1.1 mrg AccessModifierOffset: -2
30 1.4 mrg AlwaysBreakAfterReturnType: TopLevel
31 1.1 mrg BinPackArguments: true
32 1.1 mrg BinPackParameters: true
33 1.1 mrg BraceWrapping:
34 1.1 mrg AfterClass: true
35 1.1 mrg AfterControlStatement: true
36 1.1 mrg AfterEnum: true
37 1.1 mrg AfterFunction: true
38 1.1 mrg AfterNamespace: false
39 1.1 mrg AfterObjCDeclaration: true
40 1.1 mrg AfterStruct: true
41 1.1 mrg AfterUnion: true
42 1.1 mrg BeforeCatch: true
43 1.1 mrg BeforeElse: true
44 1.1 mrg IndentBraces: true
45 1.4 mrg SplitEmptyFunction: false
46 1.1 mrg BreakBeforeBinaryOperators: All
47 1.1 mrg BreakBeforeBraces: Custom
48 1.1 mrg BreakBeforeTernaryOperators: true
49 1.1 mrg ColumnLimit: 80
50 1.1 mrg ConstructorInitializerIndentWidth: 2
51 1.1 mrg ContinuationIndentWidth: 2
52 1.1 mrg ForEachMacros: [
53 1.1 mrg 'FOR_ALL_BB_FN',
54 1.1 mrg 'FOR_ALL_EH_REGION',
55 1.1 mrg 'FOR_ALL_EH_REGION_AT',
56 1.1 mrg 'FOR_ALL_EH_REGION_FN',
57 1.1 mrg 'FOR_ALL_INHERITED_FIELDS',
58 1.1 mrg 'FOR_ALL_PREDICATES',
59 1.1 mrg 'FOR_BB_BETWEEN',
60 1.1 mrg 'FOR_BB_INSNS',
61 1.1 mrg 'FOR_BB_INSNS_REVERSE',
62 1.1 mrg 'FOR_BB_INSNS_REVERSE_SAFE',
63 1.1 mrg 'FOR_BB_INSNS_SAFE',
64 1.1 mrg 'FOR_BODY',
65 1.1 mrg 'FOR_COND',
66 1.1 mrg 'FOR_EACH_AGGR_INIT_EXPR_ARG',
67 1.1 mrg 'FOR_EACH_ALIAS',
68 1.1 mrg 'FOR_EACH_ALLOCNO',
69 1.1 mrg 'FOR_EACH_ALLOCNO_OBJECT',
70 1.1 mrg 'FOR_EACH_ARTIFICIAL_DEF',
71 1.1 mrg 'FOR_EACH_ARTIFICIAL_USE',
72 1.1 mrg 'FOR_EACH_BB_FN',
73 1.1 mrg 'FOR_EACH_BB_REVERSE_FN',
74 1.1 mrg 'FOR_EACH_BIT_IN_MINMAX_SET',
75 1.1 mrg 'FOR_EACH_CALL_EXPR_ARG',
76 1.1 mrg 'FOR_EACH_CLONE',
77 1.1 mrg 'FOR_EACH_CONST_CALL_EXPR_ARG',
78 1.1 mrg 'FOR_EACH_CONSTRUCTOR_ELT',
79 1.1 mrg 'FOR_EACH_CONSTRUCTOR_VALUE',
80 1.1 mrg 'FOR_EACH_COPY',
81 1.1 mrg 'FOR_EACH_DEF',
82 1.1 mrg 'FOR_EACH_DEFINED_FUNCTION',
83 1.1 mrg 'FOR_EACH_DEFINED_SYMBOL',
84 1.1 mrg 'FOR_EACH_DEFINED_VARIABLE',
85 1.1 mrg 'FOR_EACH_DEP',
86 1.1 mrg 'FOR_EACH_EDGE',
87 1.1 mrg 'FOR_EACH_EXPR',
88 1.1 mrg 'FOR_EACH_EXPR_1',
89 1.1 mrg 'FOR_EACH_FUNCTION',
90 1.1 mrg 'FOREACH_FUNCTION_ARGS',
91 1.1 mrg 'FOREACH_FUNCTION_ARGS_PTR',
92 1.1 mrg 'FOR_EACH_FUNCTION_WITH_GIMPLE_BODY',
93 1.1 mrg 'FOR_EACH_HASH_TABLE_ELEMENT',
94 1.1 mrg 'FOR_EACH_IMM_USE_FAST',
95 1.1 mrg 'FOR_EACH_IMM_USE_ON_STMT',
96 1.1 mrg 'FOR_EACH_IMM_USE_STMT',
97 1.1 mrg 'FOR_EACH_INSN',
98 1.1 mrg 'FOR_EACH_INSN_1',
99 1.1 mrg 'FOR_EACH_INSN_DEF',
100 1.1 mrg 'FOR_EACH_INSN_EQ_USE',
101 1.1 mrg 'FOR_EACH_INSN_INFO_DEF',
102 1.1 mrg 'FOR_EACH_INSN_INFO_EQ_USE',
103 1.1 mrg 'FOR_EACH_INSN_INFO_MW',
104 1.1 mrg 'FOR_EACH_INSN_INFO_USE',
105 1.1 mrg 'FOR_EACH_INSN_USE',
106 1.1 mrg 'FOR_EACH_LOCAL_DECL',
107 1.1 mrg 'FOR_EACH_LOOP',
108 1.1 mrg 'FOR_EACH_LOOP_FN',
109 1.1 mrg 'FOR_EACH_OBJECT',
110 1.1 mrg 'FOR_EACH_OBJECT_CONFLICT',
111 1.1 mrg 'FOR_EACH_PHI_ARG',
112 1.1 mrg 'FOR_EACH_PHI_OR_STMT_DEF',
113 1.1 mrg 'FOR_EACH_PHI_OR_STMT_USE',
114 1.1 mrg 'FOR_EACH_PREF',
115 1.1 mrg 'FOR_EACH_SCALAR',
116 1.1 mrg 'FOR_EACH_SSA_DEF_OPERAND',
117 1.1 mrg 'FOR_EACH_SSA_TREE_OPERAND',
118 1.1 mrg 'FOR_EACH_SSA_USE_OPERAND',
119 1.1 mrg 'FOR_EACH_STATIC_INITIALIZER',
120 1.1 mrg 'FOR_EACH_SUBRTX',
121 1.1 mrg 'FOR_EACH_SUBRTX_PTR',
122 1.1 mrg 'FOR_EACH_SUBRTX_VAR',
123 1.1 mrg 'FOR_EACH_SUCC',
124 1.1 mrg 'FOR_EACH_SUCC_1',
125 1.1 mrg 'FOR_EACH_SYMBOL',
126 1.1 mrg 'FOR_EACH_VARIABLE',
127 1.1 mrg 'FOR_EACH_VEC_ELT',
128 1.1 mrg 'FOR_EACH_VEC_ELT_FROM',
129 1.1 mrg 'FOR_EACH_VEC_ELT_REVERSE',
130 1.1 mrg 'FOR_EACH_VEC_SAFE_ELT',
131 1.1 mrg 'FOR_EACH_VEC_SAFE_ELT_REVERSE',
132 1.1 mrg 'FOR_EXPR',
133 1.1 mrg 'FOR_INIT_STMT',
134 1.1 mrg 'FOR_SCOPE'
135 1.1 mrg ]
136 1.1 mrg IndentCaseLabels: false
137 1.1 mrg NamespaceIndentation: None
138 1.1 mrg PenaltyBreakBeforeFirstCallParameter: 100
139 1.1 mrg PointerAlignment: Right
140 1.1 mrg SortIncludes: false
141 1.1 mrg SpaceAfterCStyleCast: true
142 1.1 mrg SpaceBeforeParens: Always
143 1.1 mrg SpacesBeforeTrailingComments: 1
144 1.1 mrg UseTab: Always
145 1.4 mrg AlignEscapedNewlines: Right
146 1.4 mrg AlignTrailingComments: true
147 1.4 mrg AllowShortFunctionsOnASingleLine: All
148 1.4 mrg AlwaysBreakTemplateDeclarations: MultiLine
149 1.4 mrg KeepEmptyLinesAtTheStartOfBlocks: false
150 1.4 mrg Standard: Cpp03
151