mirror of
				https://github.com/python/cpython.git
				synced 2025-11-01 06:01:29 +00:00 
			
		
		
		
	Issue #27810: Rerun Argument Clinic on all modules
This commit is contained in:
		
							parent
							
								
									f0ccbbbc57
								
							
						
					
					
						commit
						37e4ef7b17
					
				
					 25 changed files with 453 additions and 452 deletions
				
			
		|  | @ -51,14 +51,14 @@ PyDoc_STRVAR(bytearray_translate__doc__, | |||
| "The remaining characters are mapped through the given translation table."); | ||||
| 
 | ||||
| #define BYTEARRAY_TRANSLATE_METHODDEF    \ | ||||
|     {"translate", (PyCFunction)bytearray_translate, METH_VARARGS|METH_KEYWORDS, bytearray_translate__doc__}, | ||||
|     {"translate", (PyCFunction)bytearray_translate, METH_FASTCALL, bytearray_translate__doc__}, | ||||
| 
 | ||||
| static PyObject * | ||||
| bytearray_translate_impl(PyByteArrayObject *self, PyObject *table, | ||||
|                          PyObject *deletechars); | ||||
| 
 | ||||
| static PyObject * | ||||
| bytearray_translate(PyByteArrayObject *self, PyObject *args, PyObject *kwargs) | ||||
| bytearray_translate(PyByteArrayObject *self, PyObject **args, Py_ssize_t nargs, PyObject *kwnames) | ||||
| { | ||||
|     PyObject *return_value = NULL; | ||||
|     static const char * const _keywords[] = {"", "delete", NULL}; | ||||
|  | @ -66,7 +66,7 @@ bytearray_translate(PyByteArrayObject *self, PyObject *args, PyObject *kwargs) | |||
|     PyObject *table; | ||||
|     PyObject *deletechars = NULL; | ||||
| 
 | ||||
|     if (!_PyArg_ParseTupleAndKeywordsFast(args, kwargs, &_parser, | ||||
|     if (!_PyArg_ParseStack(args, nargs, kwnames, &_parser, | ||||
|         &table, &deletechars)) { | ||||
|         goto exit; | ||||
|     } | ||||
|  | @ -181,14 +181,14 @@ PyDoc_STRVAR(bytearray_split__doc__, | |||
| "    -1 (the default value) means no limit."); | ||||
| 
 | ||||
| #define BYTEARRAY_SPLIT_METHODDEF    \ | ||||
|     {"split", (PyCFunction)bytearray_split, METH_VARARGS|METH_KEYWORDS, bytearray_split__doc__}, | ||||
|     {"split", (PyCFunction)bytearray_split, METH_FASTCALL, bytearray_split__doc__}, | ||||
| 
 | ||||
| static PyObject * | ||||
| bytearray_split_impl(PyByteArrayObject *self, PyObject *sep, | ||||
|                      Py_ssize_t maxsplit); | ||||
| 
 | ||||
| static PyObject * | ||||
| bytearray_split(PyByteArrayObject *self, PyObject *args, PyObject *kwargs) | ||||
| bytearray_split(PyByteArrayObject *self, PyObject **args, Py_ssize_t nargs, PyObject *kwnames) | ||||
| { | ||||
|     PyObject *return_value = NULL; | ||||
|     static const char * const _keywords[] = {"sep", "maxsplit", NULL}; | ||||
|  | @ -196,7 +196,7 @@ bytearray_split(PyByteArrayObject *self, PyObject *args, PyObject *kwargs) | |||
|     PyObject *sep = Py_None; | ||||
|     Py_ssize_t maxsplit = -1; | ||||
| 
 | ||||
|     if (!_PyArg_ParseTupleAndKeywordsFast(args, kwargs, &_parser, | ||||
|     if (!_PyArg_ParseStack(args, nargs, kwnames, &_parser, | ||||
|         &sep, &maxsplit)) { | ||||
|         goto exit; | ||||
|     } | ||||
|  | @ -255,14 +255,14 @@ PyDoc_STRVAR(bytearray_rsplit__doc__, | |||
| "Splitting is done starting at the end of the bytearray and working to the front."); | ||||
| 
 | ||||
| #define BYTEARRAY_RSPLIT_METHODDEF    \ | ||||
|     {"rsplit", (PyCFunction)bytearray_rsplit, METH_VARARGS|METH_KEYWORDS, bytearray_rsplit__doc__}, | ||||
|     {"rsplit", (PyCFunction)bytearray_rsplit, METH_FASTCALL, bytearray_rsplit__doc__}, | ||||
| 
 | ||||
| static PyObject * | ||||
| bytearray_rsplit_impl(PyByteArrayObject *self, PyObject *sep, | ||||
|                       Py_ssize_t maxsplit); | ||||
| 
 | ||||
| static PyObject * | ||||
| bytearray_rsplit(PyByteArrayObject *self, PyObject *args, PyObject *kwargs) | ||||
| bytearray_rsplit(PyByteArrayObject *self, PyObject **args, Py_ssize_t nargs, PyObject *kwnames) | ||||
| { | ||||
|     PyObject *return_value = NULL; | ||||
|     static const char * const _keywords[] = {"sep", "maxsplit", NULL}; | ||||
|  | @ -270,7 +270,7 @@ bytearray_rsplit(PyByteArrayObject *self, PyObject *args, PyObject *kwargs) | |||
|     PyObject *sep = Py_None; | ||||
|     Py_ssize_t maxsplit = -1; | ||||
| 
 | ||||
|     if (!_PyArg_ParseTupleAndKeywordsFast(args, kwargs, &_parser, | ||||
|     if (!_PyArg_ParseStack(args, nargs, kwnames, &_parser, | ||||
|         &sep, &maxsplit)) { | ||||
|         goto exit; | ||||
|     } | ||||
|  | @ -547,14 +547,14 @@ PyDoc_STRVAR(bytearray_decode__doc__, | |||
| "    can handle UnicodeDecodeErrors."); | ||||
| 
 | ||||
| #define BYTEARRAY_DECODE_METHODDEF    \ | ||||
|     {"decode", (PyCFunction)bytearray_decode, METH_VARARGS|METH_KEYWORDS, bytearray_decode__doc__}, | ||||
|     {"decode", (PyCFunction)bytearray_decode, METH_FASTCALL, bytearray_decode__doc__}, | ||||
| 
 | ||||
| static PyObject * | ||||
| bytearray_decode_impl(PyByteArrayObject *self, const char *encoding, | ||||
|                       const char *errors); | ||||
| 
 | ||||
| static PyObject * | ||||
| bytearray_decode(PyByteArrayObject *self, PyObject *args, PyObject *kwargs) | ||||
| bytearray_decode(PyByteArrayObject *self, PyObject **args, Py_ssize_t nargs, PyObject *kwnames) | ||||
| { | ||||
|     PyObject *return_value = NULL; | ||||
|     static const char * const _keywords[] = {"encoding", "errors", NULL}; | ||||
|  | @ -562,7 +562,7 @@ bytearray_decode(PyByteArrayObject *self, PyObject *args, PyObject *kwargs) | |||
|     const char *encoding = NULL; | ||||
|     const char *errors = NULL; | ||||
| 
 | ||||
|     if (!_PyArg_ParseTupleAndKeywordsFast(args, kwargs, &_parser, | ||||
|     if (!_PyArg_ParseStack(args, nargs, kwnames, &_parser, | ||||
|         &encoding, &errors)) { | ||||
|         goto exit; | ||||
|     } | ||||
|  | @ -595,20 +595,20 @@ PyDoc_STRVAR(bytearray_splitlines__doc__, | |||
| "true."); | ||||
| 
 | ||||
| #define BYTEARRAY_SPLITLINES_METHODDEF    \ | ||||
|     {"splitlines", (PyCFunction)bytearray_splitlines, METH_VARARGS|METH_KEYWORDS, bytearray_splitlines__doc__}, | ||||
|     {"splitlines", (PyCFunction)bytearray_splitlines, METH_FASTCALL, bytearray_splitlines__doc__}, | ||||
| 
 | ||||
| static PyObject * | ||||
| bytearray_splitlines_impl(PyByteArrayObject *self, int keepends); | ||||
| 
 | ||||
| static PyObject * | ||||
| bytearray_splitlines(PyByteArrayObject *self, PyObject *args, PyObject *kwargs) | ||||
| bytearray_splitlines(PyByteArrayObject *self, PyObject **args, Py_ssize_t nargs, PyObject *kwnames) | ||||
| { | ||||
|     PyObject *return_value = NULL; | ||||
|     static const char * const _keywords[] = {"keepends", NULL}; | ||||
|     static _PyArg_Parser _parser = {"|i:splitlines", _keywords, 0}; | ||||
|     int keepends = 0; | ||||
| 
 | ||||
|     if (!_PyArg_ParseTupleAndKeywordsFast(args, kwargs, &_parser, | ||||
|     if (!_PyArg_ParseStack(args, nargs, kwnames, &_parser, | ||||
|         &keepends)) { | ||||
|         goto exit; | ||||
|     } | ||||
|  | @ -711,4 +711,4 @@ bytearray_sizeof(PyByteArrayObject *self, PyObject *Py_UNUSED(ignored)) | |||
| { | ||||
|     return bytearray_sizeof_impl(self); | ||||
| } | ||||
| /*[clinic end generated code: output=59a0c86b29ff06d1 input=a9049054013a1b77]*/ | ||||
| /*[clinic end generated code: output=225342a680391b9c input=a9049054013a1b77]*/ | ||||
|  |  | |||
|  | @ -17,13 +17,13 @@ PyDoc_STRVAR(bytes_split__doc__, | |||
| "    -1 (the default value) means no limit."); | ||||
| 
 | ||||
| #define BYTES_SPLIT_METHODDEF    \ | ||||
|     {"split", (PyCFunction)bytes_split, METH_VARARGS|METH_KEYWORDS, bytes_split__doc__}, | ||||
|     {"split", (PyCFunction)bytes_split, METH_FASTCALL, bytes_split__doc__}, | ||||
| 
 | ||||
| static PyObject * | ||||
| bytes_split_impl(PyBytesObject *self, PyObject *sep, Py_ssize_t maxsplit); | ||||
| 
 | ||||
| static PyObject * | ||||
| bytes_split(PyBytesObject *self, PyObject *args, PyObject *kwargs) | ||||
| bytes_split(PyBytesObject *self, PyObject **args, Py_ssize_t nargs, PyObject *kwnames) | ||||
| { | ||||
|     PyObject *return_value = NULL; | ||||
|     static const char * const _keywords[] = {"sep", "maxsplit", NULL}; | ||||
|  | @ -31,7 +31,7 @@ bytes_split(PyBytesObject *self, PyObject *args, PyObject *kwargs) | |||
|     PyObject *sep = Py_None; | ||||
|     Py_ssize_t maxsplit = -1; | ||||
| 
 | ||||
|     if (!_PyArg_ParseTupleAndKeywordsFast(args, kwargs, &_parser, | ||||
|     if (!_PyArg_ParseStack(args, nargs, kwnames, &_parser, | ||||
|         &sep, &maxsplit)) { | ||||
|         goto exit; | ||||
|     } | ||||
|  | @ -136,13 +136,13 @@ PyDoc_STRVAR(bytes_rsplit__doc__, | |||
| "Splitting is done starting at the end of the bytes and working to the front."); | ||||
| 
 | ||||
| #define BYTES_RSPLIT_METHODDEF    \ | ||||
|     {"rsplit", (PyCFunction)bytes_rsplit, METH_VARARGS|METH_KEYWORDS, bytes_rsplit__doc__}, | ||||
|     {"rsplit", (PyCFunction)bytes_rsplit, METH_FASTCALL, bytes_rsplit__doc__}, | ||||
| 
 | ||||
| static PyObject * | ||||
| bytes_rsplit_impl(PyBytesObject *self, PyObject *sep, Py_ssize_t maxsplit); | ||||
| 
 | ||||
| static PyObject * | ||||
| bytes_rsplit(PyBytesObject *self, PyObject *args, PyObject *kwargs) | ||||
| bytes_rsplit(PyBytesObject *self, PyObject **args, Py_ssize_t nargs, PyObject *kwnames) | ||||
| { | ||||
|     PyObject *return_value = NULL; | ||||
|     static const char * const _keywords[] = {"sep", "maxsplit", NULL}; | ||||
|  | @ -150,7 +150,7 @@ bytes_rsplit(PyBytesObject *self, PyObject *args, PyObject *kwargs) | |||
|     PyObject *sep = Py_None; | ||||
|     Py_ssize_t maxsplit = -1; | ||||
| 
 | ||||
|     if (!_PyArg_ParseTupleAndKeywordsFast(args, kwargs, &_parser, | ||||
|     if (!_PyArg_ParseStack(args, nargs, kwnames, &_parser, | ||||
|         &sep, &maxsplit)) { | ||||
|         goto exit; | ||||
|     } | ||||
|  | @ -281,14 +281,14 @@ PyDoc_STRVAR(bytes_translate__doc__, | |||
| "The remaining characters are mapped through the given translation table."); | ||||
| 
 | ||||
| #define BYTES_TRANSLATE_METHODDEF    \ | ||||
|     {"translate", (PyCFunction)bytes_translate, METH_VARARGS|METH_KEYWORDS, bytes_translate__doc__}, | ||||
|     {"translate", (PyCFunction)bytes_translate, METH_FASTCALL, bytes_translate__doc__}, | ||||
| 
 | ||||
| static PyObject * | ||||
| bytes_translate_impl(PyBytesObject *self, PyObject *table, | ||||
|                      PyObject *deletechars); | ||||
| 
 | ||||
| static PyObject * | ||||
| bytes_translate(PyBytesObject *self, PyObject *args, PyObject *kwargs) | ||||
| bytes_translate(PyBytesObject *self, PyObject **args, Py_ssize_t nargs, PyObject *kwnames) | ||||
| { | ||||
|     PyObject *return_value = NULL; | ||||
|     static const char * const _keywords[] = {"", "delete", NULL}; | ||||
|  | @ -296,7 +296,7 @@ bytes_translate(PyBytesObject *self, PyObject *args, PyObject *kwargs) | |||
|     PyObject *table; | ||||
|     PyObject *deletechars = NULL; | ||||
| 
 | ||||
|     if (!_PyArg_ParseTupleAndKeywordsFast(args, kwargs, &_parser, | ||||
|     if (!_PyArg_ParseStack(args, nargs, kwnames, &_parser, | ||||
|         &table, &deletechars)) { | ||||
|         goto exit; | ||||
|     } | ||||
|  | @ -412,14 +412,14 @@ PyDoc_STRVAR(bytes_decode__doc__, | |||
| "    can handle UnicodeDecodeErrors."); | ||||
| 
 | ||||
| #define BYTES_DECODE_METHODDEF    \ | ||||
|     {"decode", (PyCFunction)bytes_decode, METH_VARARGS|METH_KEYWORDS, bytes_decode__doc__}, | ||||
|     {"decode", (PyCFunction)bytes_decode, METH_FASTCALL, bytes_decode__doc__}, | ||||
| 
 | ||||
| static PyObject * | ||||
| bytes_decode_impl(PyBytesObject *self, const char *encoding, | ||||
|                   const char *errors); | ||||
| 
 | ||||
| static PyObject * | ||||
| bytes_decode(PyBytesObject *self, PyObject *args, PyObject *kwargs) | ||||
| bytes_decode(PyBytesObject *self, PyObject **args, Py_ssize_t nargs, PyObject *kwnames) | ||||
| { | ||||
|     PyObject *return_value = NULL; | ||||
|     static const char * const _keywords[] = {"encoding", "errors", NULL}; | ||||
|  | @ -427,7 +427,7 @@ bytes_decode(PyBytesObject *self, PyObject *args, PyObject *kwargs) | |||
|     const char *encoding = NULL; | ||||
|     const char *errors = NULL; | ||||
| 
 | ||||
|     if (!_PyArg_ParseTupleAndKeywordsFast(args, kwargs, &_parser, | ||||
|     if (!_PyArg_ParseStack(args, nargs, kwnames, &_parser, | ||||
|         &encoding, &errors)) { | ||||
|         goto exit; | ||||
|     } | ||||
|  | @ -447,20 +447,20 @@ PyDoc_STRVAR(bytes_splitlines__doc__, | |||
| "true."); | ||||
| 
 | ||||
| #define BYTES_SPLITLINES_METHODDEF    \ | ||||
|     {"splitlines", (PyCFunction)bytes_splitlines, METH_VARARGS|METH_KEYWORDS, bytes_splitlines__doc__}, | ||||
|     {"splitlines", (PyCFunction)bytes_splitlines, METH_FASTCALL, bytes_splitlines__doc__}, | ||||
| 
 | ||||
| static PyObject * | ||||
| bytes_splitlines_impl(PyBytesObject *self, int keepends); | ||||
| 
 | ||||
| static PyObject * | ||||
| bytes_splitlines(PyBytesObject *self, PyObject *args, PyObject *kwargs) | ||||
| bytes_splitlines(PyBytesObject *self, PyObject **args, Py_ssize_t nargs, PyObject *kwnames) | ||||
| { | ||||
|     PyObject *return_value = NULL; | ||||
|     static const char * const _keywords[] = {"keepends", NULL}; | ||||
|     static _PyArg_Parser _parser = {"|i:splitlines", _keywords, 0}; | ||||
|     int keepends = 0; | ||||
| 
 | ||||
|     if (!_PyArg_ParseTupleAndKeywordsFast(args, kwargs, &_parser, | ||||
|     if (!_PyArg_ParseStack(args, nargs, kwnames, &_parser, | ||||
|         &keepends)) { | ||||
|         goto exit; | ||||
|     } | ||||
|  | @ -499,4 +499,4 @@ bytes_fromhex(PyTypeObject *type, PyObject *arg) | |||
| exit: | ||||
|     return return_value; | ||||
| } | ||||
| /*[clinic end generated code: output=5618c05c24c1e617 input=a9049054013a1b77]*/ | ||||
| /*[clinic end generated code: output=2dc3c93cfd2dc440 input=a9049054013a1b77]*/ | ||||
|  |  | |||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue
	
	 Victor Stinner
						Victor Stinner