Repository navigation
Commit 9b6a1a1
gh-160704: Restore C11-C17 `static_assert` fallback (GH-160705)
`_Py_STDC_VERSION` needs to be defined before its value can be checked.
In 8335bcb (gh-160208: Add a private wrapper around __STDC_VERSION__
(GH-160376), 2026-10-23), the condition `defined(_Py_STDC_VERSION)` is
incorrectly negated, which prevents the fallback definition of
`static_assert` in C11-C17 builds and causes a build error when building
with an old C library that does not define `static_assert`.
(cherry picked from commit a7ac7a8)
Signed-off-by: Ruoyu Zhong <zhongruoyu@outlook.com>
Co-authored-by: Ruoyu Zhong <zhongruoyu@outlook.com>
1 parent 3be665b commit 9b6a1a1
2 files changed
Lines changed: 3 additions & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
25 | 25 | | |
26 | 26 | | |
27 | 27 | | |
28 | | - | |
| 28 | + | |
29 | 29 | | |
30 | 30 | | |
31 | 31 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
0 commit comments