Skip to content

Commit

Permalink
Disable macro backslash alignment in clang-format
Browse files Browse the repository at this point in the history
With alignment enabled, nearly every minor change causes reformat of
whole macro
  • Loading branch information
sgizler committed Oct 10, 2024
1 parent 93e2be4 commit bab424d
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 3 deletions.
1 change: 1 addition & 0 deletions .clang-format
Original file line number Diff line number Diff line change
Expand Up @@ -2,3 +2,4 @@
BasedOnStyle: Chromium
ColumnLimit: 100
IndentWidth: 4
AlignEscapedNewlines: DontAlign
6 changes: 3 additions & 3 deletions source/Utils.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -84,8 +84,8 @@ std::string prefixLines(const std::string& str, const std::string& linePrefix);

// NOTE: doing it as variadic func rather than macro would prevent
// compiler from issuing warnings about incorrect format string
#define PRINTF_ERR(...) \
do { \
#define PRINTF_ERR(...) \
do { \
fprintf(stderr, "sv-bugpoint: "); \
fprintf(stderr, __VA_ARGS__); \
fprintf(stderr, __VA_ARGS__); \
} while (0)

0 comments on commit bab424d

Please sign in to comment.