diff options
author | Rémi Lapeyre <remi.lapeyre@henki.fr> | 2019-08-29 16:49:08 +0200 |
---|---|---|
committer | Serhiy Storchaka <storchaka@gmail.com> | 2019-08-29 17:49:08 +0300 |
commit | 4901fe274bc82b95dc89bcb3de8802a3dfedab32 (patch) | |
tree | 2e6e4d0b1cdcb499df7f049ebc9dbbdb9f392bbe /Python/clinic/bltinmodule.c.h | |
parent | 59725f3badb3028636c8906ecac4ceb0a37f3982 (diff) | |
download | cpython-git-4901fe274bc82b95dc89bcb3de8802a3dfedab32.tar.gz |
bpo-37034: Display argument name on errors with keyword arguments with Argument Clinic. (GH-13593)
Diffstat (limited to 'Python/clinic/bltinmodule.c.h')
-rw-r--r-- | Python/clinic/bltinmodule.c.h | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/Python/clinic/bltinmodule.c.h b/Python/clinic/bltinmodule.c.h index abed6cc3e1..49608ccf3d 100644 --- a/Python/clinic/bltinmodule.c.h +++ b/Python/clinic/bltinmodule.c.h @@ -102,7 +102,7 @@ builtin_format(PyObject *module, PyObject *const *args, Py_ssize_t nargs) goto skip_optional; } if (!PyUnicode_Check(args[1])) { - _PyArg_BadArgument("format", 2, "str", args[1]); + _PyArg_BadArgument("format", "argument 2", "str", args[1]); goto exit; } if (PyUnicode_READY(args[1]) == -1) { @@ -200,7 +200,7 @@ builtin_compile(PyObject *module, PyObject *const *args, Py_ssize_t nargs, PyObj goto exit; } if (!PyUnicode_Check(args[2])) { - _PyArg_BadArgument("compile", 3, "str", args[2]); + _PyArg_BadArgument("compile", "argument 'mode'", "str", args[2]); goto exit; } Py_ssize_t mode_length; @@ -849,4 +849,4 @@ builtin_issubclass(PyObject *module, PyObject *const *args, Py_ssize_t nargs) exit: return return_value; } -/*[clinic end generated code: output=e173df340a9e4516 input=a9049054013a1b77]*/ +/*[clinic end generated code: output=1927f3c9abd00c35 input=a9049054013a1b77]*/ |