-
Notifications
You must be signed in to change notification settings - Fork 12
/
.clang-format
23 lines (22 loc) · 927 Bytes
/
.clang-format
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
# SPDX-License-Identifier: Apache-2.0
#
# clang-format style file for mlkem-native
#
BasedOnStyle: Google
MaxEmptyLinesToKeep: 3
AllowShortIfStatementsOnASingleLine: false
AllowShortLoopsOnASingleLine: false
DerivePointerAlignment: false
PointerAlignment: Right
# TODO(davidben): The default for Google style is now Regroup, but the default
# IncludeCategories does not recognize <openssl/header.h>. We should
# reconfigure IncludeCategories to match. For now, keep it at Preserve.
IncludeBlocks: Preserve
# Designate CBMC contracts/macros that appear in .h files
# as "attributes" so they don't get increasingly indented line after line
BreakBeforeBraces: Allman
WhitespaceSensitiveMacros: ['__contract__', '__loop__' ]
Macros:
# Make this artifically long to avoid function bodies after short contracts
- __contract__(x)={ void a; void b; void c; void d; void e; void f; } void abcdefghijklmnopqrstuvw()
- __loop__(x)={}