From a1c898f9fcabccec803601627b6ca7dc26638842 Mon Sep 17 00:00:00 2001 From: "Ralf W. Grosse-Kunstleve" Date: Thu, 10 Feb 2022 09:16:59 -0800 Subject: [PATCH] Adding commonly used .clang-format `CommentPragmas:` --- .clang-format | 1 + tests/pybind11_tests.h | 3 +-- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.clang-format b/.clang-format index 92e726a1d1..51dc0e3dda 100644 --- a/.clang-format +++ b/.clang-format @@ -9,6 +9,7 @@ BinPackParameters: false BreakBeforeBinaryOperators: All BreakConstructorInitializers: BeforeColon ColumnLimit: 99 +CommentPragmas: 'NOLINT:.*|^ IWYU pragma:' IncludeBlocks: Regroup IndentCaseLabels: true IndentPPDirectives: AfterHash diff --git a/tests/pybind11_tests.h b/tests/pybind11_tests.h index 9b99923237..f6e1a6523b 100644 --- a/tests/pybind11_tests.h +++ b/tests/pybind11_tests.h @@ -5,8 +5,7 @@ #if defined(_MSC_VER) && _MSC_VER < 1910 // We get some really long type names here which causes MSVC 2015 to emit warnings -# pragma warning( \ - disable : 4503) // warning C4503: decorated name length exceeded, name was truncated +# pragma warning(disable : 4503) // NOLINT: warning C4503: decorated name length exceeded, name was truncated #endif namespace py = pybind11;