gh-129666: Add C11/C++11 to docs and -pedantic-errors to GCC/clang test_c[pp]ext tests (GH-130686)

This commit is contained in:
Petr Viktorin 2025-02-28 16:03:02 +01:00 committed by GitHub
parent cc17307faa
commit 003e6d2b97
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
7 changed files with 62 additions and 0 deletions

View file

@ -18,6 +18,14 @@
# 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