diff options
author | RĂ©mi Lapeyre <remi.lapeyre@henki.fr> | 2019-08-29 14:49:08 (GMT) |
---|---|---|
committer | Serhiy Storchaka <storchaka@gmail.com> | 2019-08-29 14:49:08 (GMT) |
commit | 4901fe274bc82b95dc89bcb3de8802a3dfedab32 (patch) | |
tree | 2e6e4d0b1cdcb499df7f049ebc9dbbdb9f392bbe /Modules/clinic/_lzmamodule.c.h | |
parent | 59725f3badb3028636c8906ecac4ceb0a37f3982 (diff) | |
download | cpython-4901fe274bc82b95dc89bcb3de8802a3dfedab32.zip cpython-4901fe274bc82b95dc89bcb3de8802a3dfedab32.tar.gz cpython-4901fe274bc82b95dc89bcb3de8802a3dfedab32.tar.bz2 |
bpo-37034: Display argument name on errors with keyword arguments with Argument Clinic. (GH-13593)
Diffstat (limited to 'Modules/clinic/_lzmamodule.c.h')
-rw-r--r-- | Modules/clinic/_lzmamodule.c.h | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/Modules/clinic/_lzmamodule.c.h b/Modules/clinic/_lzmamodule.c.h index 68aa770..82ef4d5 100644 --- a/Modules/clinic/_lzmamodule.c.h +++ b/Modules/clinic/_lzmamodule.c.h @@ -29,7 +29,7 @@ _lzma_LZMACompressor_compress(Compressor *self, PyObject *arg) goto exit; } if (!PyBuffer_IsContiguous(&data, 'C')) { - _PyArg_BadArgument("compress", 0, "contiguous buffer", arg); + _PyArg_BadArgument("compress", "argument", "contiguous buffer", arg); goto exit; } return_value = _lzma_LZMACompressor_compress_impl(self, &data); @@ -110,7 +110,7 @@ _lzma_LZMADecompressor_decompress(Decompressor *self, PyObject *const *args, Py_ goto exit; } if (!PyBuffer_IsContiguous(&data, 'C')) { - _PyArg_BadArgument("decompress", 1, "contiguous buffer", args[0]); + _PyArg_BadArgument("decompress", "argument 'data'", "contiguous buffer", args[0]); goto exit; } if (!noptargs) { @@ -321,7 +321,7 @@ _lzma__decode_filter_properties(PyObject *module, PyObject *const *args, Py_ssiz goto exit; } if (!PyBuffer_IsContiguous(&encoded_props, 'C')) { - _PyArg_BadArgument("_decode_filter_properties", 2, "contiguous buffer", args[1]); + _PyArg_BadArgument("_decode_filter_properties", "argument 2", "contiguous buffer", args[1]); goto exit; } return_value = _lzma__decode_filter_properties_impl(module, filter_id, &encoded_props); @@ -334,4 +334,4 @@ exit: return return_value; } -/*[clinic end generated code: output=1a290aa478603107 input=a9049054013a1b77]*/ +/*[clinic end generated code: output=f7477a10e86a717d input=a9049054013a1b77]*/ |