From 7f9992b3faca2a5c3583dadcb0b2a12bec75e148 Mon Sep 17 00:00:00 2001 From: Victor Stinner Date: Thu, 27 Jun 2024 12:22:48 +0200 Subject: [PATCH] gh-120593: Check -Wcast-qual flag in test_cext (#121081) Check the usage of the 'const' qualifier in the Python C API in test_cext. --- Lib/test/test_cext/setup.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/Lib/test/test_cext/setup.py b/Lib/test/test_cext/setup.py index ccad3fa62ad0867..383d256c1eb53b9 100644 --- a/Lib/test/test_cext/setup.py +++ b/Lib/test/test_cext/setup.py @@ -17,6 +17,9 @@ # The purpose of test_cext extension is to check that building a C # extension using the Python C API does not emit C compiler warnings. '-Werror', + + # gh-120593: Check the 'const' qualifier + '-Wcast-qual', ] if not support.Py_GIL_DISABLED: CFLAGS.append(