]> git.ipfire.org Git - thirdparty/Python/cpython.git/commitdiff
[3.14] Exclude _testclinic_depr.c.h from c-analyzer (GH-137086) (#137089)
authorMiss Islington (bot) <31488909+miss-islington@users.noreply.github.com>
Thu, 24 Jul 2025 21:36:11 +0000 (23:36 +0200)
committerGitHub <noreply@github.com>
Thu, 24 Jul 2025 21:36:11 +0000 (00:36 +0300)
Exclude _testclinic_depr.c.h from c-analyzer (GH-137086)

_testclinic.c mocks out PY_VERSION_HEX to 3.8 before including
_testclinic_depr.c.h to avoid the errors the preprocessor would
otherwise throw due to the deprecation feature it is testing.

(cherry picked from commit d5e75c07682864e9d265e11f5e4730147e7d4842)

Co-authored-by: Zachary Ware <zach@python.org>
Tools/c-analyzer/cpython/_parser.py

index cfbf0d143484993a43e6f742ec9522bd7844039d..1e754040eaf1cc41921a3d15cf6096ac308ea1f9 100644 (file)
@@ -83,6 +83,8 @@ Python/frozen_modules/*.h
 Python/generated_cases.c.h
 Python/executor_cases.c.h
 Python/optimizer_cases.c.h
+# XXX: Throws errors if PY_VERSION_HEX is not mocked out
+Modules/clinic/_testclinic_depr.c.h
 
 # not actually source
 Python/bytecodes.c