summaryrefslogtreecommitdiffstats
path: root/Modules/_io/_iomodule.c
diff options
context:
space:
mode:
authorSerhiy Storchaka <storchaka@gmail.com>2019-09-14 09:24:05 (GMT)
committerGitHub <noreply@github.com>2019-09-14 09:24:05 (GMT)
commit279f44678c8b84a183f9eeb85e0b086228154497 (patch)
tree9cacd41975bf15ab7a94fc5ba6a2df57f8e02ee5 /Modules/_io/_iomodule.c
parentd057b896f97e6d7447b9bf9246770c41cf205299 (diff)
downloadcpython-279f44678c8b84a183f9eeb85e0b086228154497.zip
cpython-279f44678c8b84a183f9eeb85e0b086228154497.tar.gz
cpython-279f44678c8b84a183f9eeb85e0b086228154497.tar.bz2
bpo-37206: Unrepresentable default values no longer represented as None. (GH-13933)
In ArgumentClinic, value "NULL" should now be used only for unrepresentable default values (like in the optional third parameter of getattr). "None" should be used if None is accepted as argument and passing None has the same effect as not passing the argument at all.
Diffstat (limited to 'Modules/_io/_iomodule.c')
-rw-r--r--Modules/_io/_iomodule.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/Modules/_io/_iomodule.c b/Modules/_io/_iomodule.c
index 162b288..b4cc894 100644
--- a/Modules/_io/_iomodule.c
+++ b/Modules/_io/_iomodule.c
@@ -103,9 +103,9 @@ _io.open
file: object
mode: str = "r"
buffering: int = -1
- encoding: str(accept={str, NoneType}) = NULL
- errors: str(accept={str, NoneType}) = NULL
- newline: str(accept={str, NoneType}) = NULL
+ encoding: str(accept={str, NoneType}) = None
+ errors: str(accept={str, NoneType}) = None
+ newline: str(accept={str, NoneType}) = None
closefd: bool(accept={int}) = True
opener: object = None
@@ -233,7 +233,7 @@ static PyObject *
_io_open_impl(PyObject *module, PyObject *file, const char *mode,
int buffering, const char *encoding, const char *errors,
const char *newline, int closefd, PyObject *opener)
-/*[clinic end generated code: output=aefafc4ce2b46dc0 input=03da2940c8a65871]*/
+/*[clinic end generated code: output=aefafc4ce2b46dc0 input=7295902222e6b311]*/
{
unsigned i;