summaryrefslogtreecommitdiffstats
path: root/lib/.clang-format
diff options
context:
space:
mode:
Diffstat (limited to 'lib/.clang-format')
-rw-r--r--lib/.clang-format21
1 files changed, 21 insertions, 0 deletions
diff --git a/lib/.clang-format b/lib/.clang-format
new file mode 100644
index 000000000..8b5c955ce
--- /dev/null
+++ b/lib/.clang-format
@@ -0,0 +1,21 @@
+# Minimal clang-format version is 8
+
+BasedOnStyle: GNU
+UseTab: Always
+SpaceAfterCStyleCast: true
+SortIncludes: false
+AlignConsecutiveMacros: true
+BreakBeforeTernaryOperators: false
+BreakBeforeBinaryOperators: None
+ContinuationIndentWidth: 2
+
+ForEachMacros:
+ - 'clib_bitmap_foreach'
+ - 'pool_foreach'
+ - 'pool_foreach_index'
+ - 'vec_foreach'
+ - 'vec_foreach_backwards'
+ - 'vec_foreach_index'
+ - 'vec_foreach_index_backwards'
+ - 'vlib_foreach_rx_tx'
+