diff options
author | Petr Viktorin <encukou@gmail.com> | 2025-02-28 16:03:02 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2025-02-28 16:03:02 +0100 |
commit | 003e6d2b9776c07147a9c628eb028fd2ac3f0008 (patch) | |
tree | 0c7400096b574488c4bd2a234ddede861881650e /Lib/test/test_cppext/setup.py | |
parent | cc17307faaa248535c65f6a7668e06dc8ef04575 (diff) | |
download | cpython-003e6d2b9776c07147a9c628eb028fd2ac3f0008.tar.gz cpython-003e6d2b9776c07147a9c628eb028fd2ac3f0008.zip |
gh-129666: Add C11/C++11 to docs and `-pedantic-errors` to GCC/clang test_c[pp]ext tests (GH-130686)
Diffstat (limited to 'Lib/test/test_cppext/setup.py')
-rw-r--r-- | Lib/test/test_cppext/setup.py | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/Lib/test/test_cppext/setup.py b/Lib/test/test_cppext/setup.py index 019ff18446a..aa09c7bc8cb 100644 --- a/Lib/test/test_cppext/setup.py +++ b/Lib/test/test_cppext/setup.py @@ -18,6 +18,14 @@ if not support.MS_WINDOWS: # a C++ extension using the Python C API does not emit C++ compiler # warnings '-Werror', + + # Ask for strict(er) compliance with the standard. + '-pedantic-errors', + + # But allow C++11 features for -std=C++03. We use: + # - `long long` (-Wno-c++11-long-long) + # - comma at end of `enum` lists (no narrower GCC option exists) + '-Wno-c++11-extensions', ] else: # MSVC compiler flags |