diff options
author | Zdenek Dohnal <zdohnal@redhat.com> | 2023-08-15 22:52:01 +0200 |
---|---|---|
committer | Christian Brabandt <cb@256bit.org> | 2023-08-15 22:52:01 +0200 |
commit | 15a0a0281a060fd5968ca2f3c80e750137106adb (patch) | |
tree | 0a37bca9a1560949672d15df5157630be645e8a3 /src/if_python3.c | |
parent | 7772c93a3ec1ce60469e9aea9899687ae1141f34 (diff) |
patch 9.0.1716: Windows build with python 3.12 and clang failsv9.0.1716
Problem: Windows build with python 3.12 and clang fails
Solution: Remove the PyBool_Type function pointer for python 3.12
Clang on Win doesn't like non-static functions in static struct with
Python 3.12 - removing the new obfuscated function and protecting the
old PyBool function for older Pythons fixes the issue.
closes: #12800
Signed-off-by: Christian Brabandt <cb@256bit.org>
Co-authored-by: Zdenek Dohnal <zdohnal@redhat.com>
Diffstat (limited to 'src/if_python3.c')
-rw-r--r-- | src/if_python3.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/src/if_python3.c b/src/if_python3.c index 0a0d31e698..e4d4a90ed0 100644 --- a/src/if_python3.c +++ b/src/if_python3.c @@ -628,9 +628,8 @@ static struct {"PyStdPrinter_Type", (PYTHON_PROC*)&py3_PyStdPrinter_Type}, {"PySlice_Type", (PYTHON_PROC*)&py3_PySlice_Type}, {"PyFloat_Type", (PYTHON_PROC*)&py3_PyFloat_Type}, +# if PY_VERSION_HEX < 0x030c00b0 {"PyBool_Type", (PYTHON_PROC*)&py3_PyBool_Type}, -# if PY_VERSION_HEX >= 0x030c00b0 - {"PyLong_Type", (PYTHON_PROC*)&py3_PyLong_Type}, # endif {"PyNumber_Check", (PYTHON_PROC*)&py3_PyNumber_Check}, {"PyNumber_Long", (PYTHON_PROC*)&py3_PyNumber_Long}, |