Skip to content

Commit

Permalink
clang-tidy: ignore dynamic_modules/abi.h and test C programs (#37426)
Browse files Browse the repository at this point in the history
part of #28566

---------

Signed-off-by: Takeshi Yoneda <[email protected]>
  • Loading branch information
mathetake authored Nov 29, 2024
1 parent ce11ceb commit d12a9c3
Show file tree
Hide file tree
Showing 4 changed files with 10 additions and 1 deletion.
5 changes: 5 additions & 0 deletions source/extensions/dynamic_modules/abi.h
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,9 @@

// NOLINT(namespace-envoy)

// This is a pure C header, so we can't apply clang-tidy to it.
// NOLINTBEGIN

// This is a pure C header file that defines the ABI of the core of dynamic modules used by Envoy.
//
// This must not contain any dependencies besides standard library since it is not only used by
Expand Down Expand Up @@ -127,3 +130,5 @@ void envoy_dynamic_module_on_http_filter_config_destroy(
#ifdef __cplusplus
}
#endif

// NOLINTEND
2 changes: 1 addition & 1 deletion source/extensions/dynamic_modules/abi_version.h
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ namespace DynamicModules {
#endif
// This is the ABI version calculated as a sha256 hash of the ABI header files. When the ABI
// changes, this value must change, and the correctness of this value is checked by the test.
const char* kAbiVersion = "cf6fef3e32daba5206ecff01c3569fd4b8d7a07cef6b36822c8e03aeff97fec9";
const char* kAbiVersion = "332d7c7fbfc7f5af6b48eece62dcb316ae070e389f810ff373e3d3d457d37b5b";

#ifdef __cplusplus
} // namespace DynamicModules
Expand Down
2 changes: 2 additions & 0 deletions test/extensions/dynamic_modules/test_data/c/test_data.bzl
Original file line number Diff line number Diff line change
Expand Up @@ -10,5 +10,7 @@ def test_program(name):
"-shared",
"-fPIC",
],
# All programs here are C, not C++, so we don't need to apply clang-tidy.
tags = ["notidy"],
linkstatic = False,
)
2 changes: 2 additions & 0 deletions tools/spelling/spelling_dictionary.txt
Original file line number Diff line number Diff line change
Expand Up @@ -314,6 +314,8 @@ NODATA
NODELAY
NODELETE
NOLINT
NOLINTBEGIN
NOLINTEND
NOLINTNEXTLINE
NONAME
NONBLOCK
Expand Down

0 comments on commit d12a9c3

Please sign in to comment.