-
Notifications
You must be signed in to change notification settings - Fork 99
Expand file tree
/
Copy path.clang-format
More file actions
executable file
·50 lines (40 loc) · 1.46 KB
/
Copy path.clang-format
File metadata and controls
executable file
·50 lines (40 loc) · 1.46 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
# CrispASR .clang-format
# Based on the existing code style: 4-space indent, 120-col limit,
# references attached to type ("const std::string & s" style).
---
Language: Cpp
BasedOnStyle: LLVM
# Indentation
IndentWidth: 4
ContinuationIndentWidth: 4
TabWidth: 4
UseTab: Never
AccessModifierOffset: -4
# Column limit — generous to avoid wrapping long ggml API call chains.
ColumnLimit: 120
# Brace / block style — K&R style (open brace on same line for functions).
BreakBeforeBraces: Attach
# Pointer / reference alignment — matches the codebase ("const T & x" style).
PointerAlignment: Left
ReferenceAlignment: Left
# Namespace / include style
NamespaceIndentation: None
SortIncludes: false # don't reorder existing carefully-grouped includes
# Function argument / initialiser alignment
AlignAfterOpenBracket: Align
BinPackArguments: true
BinPackParameters: true
AllowShortFunctionsOnASingleLine: Inline
AllowShortIfStatementsOnASingleLine: Never
AllowShortLoopsOnASingleLine: false
# Trailing whitespace / empty lines
MaxEmptyLinesToKeep: 2
KeepEmptyLinesAtTheStartOfBlocks: false
# Comment style
ReflowComments: false # don't reflow hand-written ASCII diagrams / tables
# Penalty tuning — keep long ggml call chains on one line when they fit.
PenaltyBreakBeforeFirstCallParameter: 19
PenaltyReturnTypeOnItsOwnLine: 300
# C++17 features present in the codebase
Standard: c++17
...