-
Notifications
You must be signed in to change notification settings - Fork 69
Expand file tree
/
Copy path.clang-format
More file actions
34 lines (27 loc) · 972 Bytes
/
.clang-format
File metadata and controls
34 lines (27 loc) · 972 Bytes
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
BasedOnStyle: LLVM
UseTab: Never
IndentWidth: 4
TabWidth: 4
AccessModifierOffset: -2
BreakBeforeBraces: Stroustrup
FixNamespaceComments: true
ColumnLimit: 100
SortIncludes: CaseSensitive
IncludeBlocks: Regroup
# NOTE: Ensure that lists are always sorted alphabetically.
IncludeCategories:
# System/STL
- Regex: '^(<)(([^.]+)|((std.*|complex|sys.*|dlfcn)\.h))(>)$'
Priority: 1
# Dependencies
- Regex: '^(")(llvm|Enzyme|absl|boost|catch2|gmock|gtest|jax_cpu_lapack_kernels|mlir|nanobind|nlohmann|numpy|pybind11|stablehlo|stim|toml\+\+|xla)(.*)\.([hcp]+)(")$'
Priority: 2
# Local headers
- Regex: '^(")(CAPI|Catalyst|Driver|Gradient|GradMethods|hlo-extensions|Ion|MBQC|Mitigation|PBC|PauliFrame|QRef|QecLogical|QecPhysical|Quantum|RTIO|Standalone|Test)(.*\/.*)\.([hcp]+)(")$'
Priority: 3
# Private headers
- Regex: '^(")([^\.\/]+)\.([hcp]+)(")$'
Priority: 4
# Unsorted headers (catch-all)
- Regex: '^(.*)$'
Priority: 5