diff options
author | Serhiy Storchaka <storchaka@gmail.com> | 2021-03-16 06:03:37 (GMT) |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-03-16 06:03:37 (GMT) |
commit | 651fc30af7ac6138764106b87632cabca56a98bb (patch) | |
tree | c656dd7a77205b7925b74a34ab34d73d5445e2a6 /Modules/_io | |
parent | a838e477a009bae4549f10bfd3396b8d5678415d (diff) | |
download | cpython-651fc30af7ac6138764106b87632cabca56a98bb.zip cpython-651fc30af7ac6138764106b87632cabca56a98bb.tar.gz cpython-651fc30af7ac6138764106b87632cabca56a98bb.tar.bz2 |
bpo-43499: Silence compiler warnings about using legacy C API on Windows (GH-24873)
Diffstat (limited to 'Modules/_io')
-rw-r--r-- | Modules/_io/fileio.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/Modules/_io/fileio.c b/Modules/_io/fileio.c index caf91df..048484b 100644 --- a/Modules/_io/fileio.c +++ b/Modules/_io/fileio.c @@ -276,7 +276,10 @@ _io_FileIO___init___impl(fileio *self, PyObject *nameobj, const char *mode, if (!PyUnicode_FSDecoder(nameobj, &stringobj)) { return -1; } +_Py_COMP_DIAG_PUSH +_Py_COMP_DIAG_IGNORE_DEPR_DECLS widename = PyUnicode_AsUnicode(stringobj); +_Py_COMP_DIAG_POP if (widename == NULL) return -1; #else |