Skip to content

Commit ec7c09b

Browse files
authored
bpo-44113: Fix compiler warning in PySys_AddWarnOption() (GH-26084)
Ignore Py_DEPRECATED() warning on purpose.
1 parent 8ea350e commit ec7c09b

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

Python/sysmodule.c

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2293,7 +2293,10 @@ PySys_AddWarnOption(const wchar_t *s)
22932293
unicode = PyUnicode_FromWideChar(s, -1);
22942294
if (unicode == NULL)
22952295
return;
2296+
_Py_COMP_DIAG_PUSH
2297+
_Py_COMP_DIAG_IGNORE_DEPR_DECLS
22962298
PySys_AddWarnOptionUnicode(unicode);
2299+
_Py_COMP_DIAG_POP
22972300
Py_DECREF(unicode);
22982301
}
22992302

0 commit comments

Comments
 (0)