Skip to content

Commit 498e8bb

Browse files
committed
Also allow the -Wzero-as-null-pointer-constant warning
1 parent b3b4ec8 commit 498e8bb

File tree

2 files changed

+1
-4
lines changed

2 files changed

+1
-4
lines changed

Lib/test/setup_testcppext.py

-3
Original file line numberDiff line numberDiff line change
@@ -35,9 +35,6 @@ def main():
3535
name = '_testcpp11ext'
3636

3737
cppflags = [*CPPFLAGS, f'-std={std}']
38-
if std == 'c++11':
39-
# Warn when using NULL rather than _Py_NULL in static inline functions
40-
cppflags.append('-Wzero-as-null-pointer-constant')
4138

4239
cpp_ext = Extension(
4340
name,
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
11
Python again uses C-style casts for most casting operations when compiled
22
with C++. This may trigger compiler warnings, if they are enabled with e.g.
3-
``g++ -Wold-style-cast``.
3+
``-Wold-style-cast `` or ``-Wzero-as-null-pointer-constant`` options for ``g++``.

0 commit comments

Comments
 (0)