From f55c891a65ed76e593be4108939cf6998036646a Mon Sep 17 00:00:00 2001 From: fanquake Date: Mon, 16 Mar 2026 20:15:10 +0800 Subject: [PATCH] lint: more reuse of SHARED_EXCLUDED_SUBTREES --- test/lint/lint-include-guards.py | 1 - test/lint/lint-locale-dependence.py | 9 +++------ test/lint/lint_ignore_dirs.py | 1 + 3 files changed, 4 insertions(+), 7 deletions(-) diff --git a/test/lint/lint-include-guards.py b/test/lint/lint-include-guards.py index dbbf0325c4e..4518f458d51 100755 --- a/test/lint/lint-include-guards.py +++ b/test/lint/lint-include-guards.py @@ -19,7 +19,6 @@ HEADER_ID_PREFIX = 'BITCOIN_' HEADER_ID_SUFFIX = '_H' EXCLUDE_FILES_WITH_PREFIX = ['contrib/devtools/bitcoin-tidy', - 'src/crypto/ctaes', 'src/tinyformat.h', 'src/bench/nanobench.h', 'src/test/fuzz/FuzzedDataProvider.h'] + SHARED_EXCLUDED_SUBTREES diff --git a/test/lint/lint-locale-dependence.py b/test/lint/lint-locale-dependence.py index c6a64587091..4957c694dac 100755 --- a/test/lint/lint-locale-dependence.py +++ b/test/lint/lint-locale-dependence.py @@ -40,6 +40,8 @@ import sys from subprocess import check_output, CalledProcessError +from lint_ignore_dirs import SHARED_EXCLUDED_SUBTREES + KNOWN_VIOLATIONS = [ "src/dbwrapper.cpp:.*vsnprintf", @@ -50,13 +52,8 @@ KNOWN_VIOLATIONS = [ ] REGEXP_EXTERNAL_DEPENDENCIES_EXCLUSIONS = [ - "src/crypto/ctaes/", - "src/ipc/libmultiprocess/", - "src/leveldb/", - "src/secp256k1/", - "src/minisketch/", "src/tinyformat.h", -] +] + SHARED_EXCLUDED_SUBTREES LOCALE_DEPENDENT_FUNCTIONS = [ "alphasort", # LC_COLLATE (via strcoll) diff --git a/test/lint/lint_ignore_dirs.py b/test/lint/lint_ignore_dirs.py index 838f01b6664..60637832309 100644 --- a/test/lint/lint_ignore_dirs.py +++ b/test/lint/lint_ignore_dirs.py @@ -9,4 +9,5 @@ SHARED_EXCLUDED_SUBTREES = ["src/leveldb/", "src/secp256k1/", "src/minisketch/", "src/ipc/libmultiprocess/", + "src/crypto/ctaes/", ]