gh-111178: Generate correct signature for most self converters (#128447)

This commit is contained in:
Erlend E. Aasland 2025-01-20 12:40:18 +01:00 committed by GitHub
parent 4d0a6595a0
commit 537296cdcd
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
74 changed files with 1627 additions and 1631 deletions

View file

@ -123,7 +123,7 @@ bytearray_find_impl(PyByteArrayObject *self, PyObject *sub, Py_ssize_t start,
Py_ssize_t end);
static PyObject *
bytearray_find(PyByteArrayObject *self, PyObject *const *args, Py_ssize_t nargs)
bytearray_find(PyObject *self, PyObject *const *args, Py_ssize_t nargs)
{
PyObject *return_value = NULL;
PyObject *sub;
@ -147,7 +147,7 @@ bytearray_find(PyByteArrayObject *self, PyObject *const *args, Py_ssize_t nargs)
goto exit;
}
skip_optional:
return_value = bytearray_find_impl(self, sub, start, end);
return_value = bytearray_find_impl((PyByteArrayObject *)self, sub, start, end);
exit:
return return_value;
@ -172,7 +172,7 @@ bytearray_count_impl(PyByteArrayObject *self, PyObject *sub,
Py_ssize_t start, Py_ssize_t end);
static PyObject *
bytearray_count(PyByteArrayObject *self, PyObject *const *args, Py_ssize_t nargs)
bytearray_count(PyObject *self, PyObject *const *args, Py_ssize_t nargs)
{
PyObject *return_value = NULL;
PyObject *sub;
@ -196,7 +196,7 @@ bytearray_count(PyByteArrayObject *self, PyObject *const *args, Py_ssize_t nargs
goto exit;
}
skip_optional:
return_value = bytearray_count_impl(self, sub, start, end);
return_value = bytearray_count_impl((PyByteArrayObject *)self, sub, start, end);
exit:
return return_value;
@ -215,9 +215,9 @@ static PyObject *
bytearray_clear_impl(PyByteArrayObject *self);
static PyObject *
bytearray_clear(PyByteArrayObject *self, PyObject *Py_UNUSED(ignored))
bytearray_clear(PyObject *self, PyObject *Py_UNUSED(ignored))
{
return bytearray_clear_impl(self);
return bytearray_clear_impl((PyByteArrayObject *)self);
}
PyDoc_STRVAR(bytearray_copy__doc__,
@ -233,9 +233,9 @@ static PyObject *
bytearray_copy_impl(PyByteArrayObject *self);
static PyObject *
bytearray_copy(PyByteArrayObject *self, PyObject *Py_UNUSED(ignored))
bytearray_copy(PyObject *self, PyObject *Py_UNUSED(ignored))
{
return bytearray_copy_impl(self);
return bytearray_copy_impl((PyByteArrayObject *)self);
}
PyDoc_STRVAR(bytearray_index__doc__,
@ -259,7 +259,7 @@ bytearray_index_impl(PyByteArrayObject *self, PyObject *sub,
Py_ssize_t start, Py_ssize_t end);
static PyObject *
bytearray_index(PyByteArrayObject *self, PyObject *const *args, Py_ssize_t nargs)
bytearray_index(PyObject *self, PyObject *const *args, Py_ssize_t nargs)
{
PyObject *return_value = NULL;
PyObject *sub;
@ -283,7 +283,7 @@ bytearray_index(PyByteArrayObject *self, PyObject *const *args, Py_ssize_t nargs
goto exit;
}
skip_optional:
return_value = bytearray_index_impl(self, sub, start, end);
return_value = bytearray_index_impl((PyByteArrayObject *)self, sub, start, end);
exit:
return return_value;
@ -310,7 +310,7 @@ bytearray_rfind_impl(PyByteArrayObject *self, PyObject *sub,
Py_ssize_t start, Py_ssize_t end);
static PyObject *
bytearray_rfind(PyByteArrayObject *self, PyObject *const *args, Py_ssize_t nargs)
bytearray_rfind(PyObject *self, PyObject *const *args, Py_ssize_t nargs)
{
PyObject *return_value = NULL;
PyObject *sub;
@ -334,7 +334,7 @@ bytearray_rfind(PyByteArrayObject *self, PyObject *const *args, Py_ssize_t nargs
goto exit;
}
skip_optional:
return_value = bytearray_rfind_impl(self, sub, start, end);
return_value = bytearray_rfind_impl((PyByteArrayObject *)self, sub, start, end);
exit:
return return_value;
@ -361,7 +361,7 @@ bytearray_rindex_impl(PyByteArrayObject *self, PyObject *sub,
Py_ssize_t start, Py_ssize_t end);
static PyObject *
bytearray_rindex(PyByteArrayObject *self, PyObject *const *args, Py_ssize_t nargs)
bytearray_rindex(PyObject *self, PyObject *const *args, Py_ssize_t nargs)
{
PyObject *return_value = NULL;
PyObject *sub;
@ -385,7 +385,7 @@ bytearray_rindex(PyByteArrayObject *self, PyObject *const *args, Py_ssize_t narg
goto exit;
}
skip_optional:
return_value = bytearray_rindex_impl(self, sub, start, end);
return_value = bytearray_rindex_impl((PyByteArrayObject *)self, sub, start, end);
exit:
return return_value;
@ -412,7 +412,7 @@ bytearray_startswith_impl(PyByteArrayObject *self, PyObject *subobj,
Py_ssize_t start, Py_ssize_t end);
static PyObject *
bytearray_startswith(PyByteArrayObject *self, PyObject *const *args, Py_ssize_t nargs)
bytearray_startswith(PyObject *self, PyObject *const *args, Py_ssize_t nargs)
{
PyObject *return_value = NULL;
PyObject *subobj;
@ -436,7 +436,7 @@ bytearray_startswith(PyByteArrayObject *self, PyObject *const *args, Py_ssize_t
goto exit;
}
skip_optional:
return_value = bytearray_startswith_impl(self, subobj, start, end);
return_value = bytearray_startswith_impl((PyByteArrayObject *)self, subobj, start, end);
exit:
return return_value;
@ -463,7 +463,7 @@ bytearray_endswith_impl(PyByteArrayObject *self, PyObject *subobj,
Py_ssize_t start, Py_ssize_t end);
static PyObject *
bytearray_endswith(PyByteArrayObject *self, PyObject *const *args, Py_ssize_t nargs)
bytearray_endswith(PyObject *self, PyObject *const *args, Py_ssize_t nargs)
{
PyObject *return_value = NULL;
PyObject *subobj;
@ -487,7 +487,7 @@ bytearray_endswith(PyByteArrayObject *self, PyObject *const *args, Py_ssize_t na
goto exit;
}
skip_optional:
return_value = bytearray_endswith_impl(self, subobj, start, end);
return_value = bytearray_endswith_impl((PyByteArrayObject *)self, subobj, start, end);
exit:
return return_value;
@ -510,7 +510,7 @@ static PyObject *
bytearray_removeprefix_impl(PyByteArrayObject *self, Py_buffer *prefix);
static PyObject *
bytearray_removeprefix(PyByteArrayObject *self, PyObject *arg)
bytearray_removeprefix(PyObject *self, PyObject *arg)
{
PyObject *return_value = NULL;
Py_buffer prefix = {NULL, NULL};
@ -518,7 +518,7 @@ bytearray_removeprefix(PyByteArrayObject *self, PyObject *arg)
if (PyObject_GetBuffer(arg, &prefix, PyBUF_SIMPLE) != 0) {
goto exit;
}
return_value = bytearray_removeprefix_impl(self, &prefix);
return_value = bytearray_removeprefix_impl((PyByteArrayObject *)self, &prefix);
exit:
/* Cleanup for prefix */
@ -546,7 +546,7 @@ static PyObject *
bytearray_removesuffix_impl(PyByteArrayObject *self, Py_buffer *suffix);
static PyObject *
bytearray_removesuffix(PyByteArrayObject *self, PyObject *arg)
bytearray_removesuffix(PyObject *self, PyObject *arg)
{
PyObject *return_value = NULL;
Py_buffer suffix = {NULL, NULL};
@ -554,7 +554,7 @@ bytearray_removesuffix(PyByteArrayObject *self, PyObject *arg)
if (PyObject_GetBuffer(arg, &suffix, PyBUF_SIMPLE) != 0) {
goto exit;
}
return_value = bytearray_removesuffix_impl(self, &suffix);
return_value = bytearray_removesuffix_impl((PyByteArrayObject *)self, &suffix);
exit:
/* Cleanup for suffix */
@ -585,7 +585,7 @@ bytearray_translate_impl(PyByteArrayObject *self, PyObject *table,
PyObject *deletechars);
static PyObject *
bytearray_translate(PyByteArrayObject *self, PyObject *const *args, Py_ssize_t nargs, PyObject *kwnames)
bytearray_translate(PyObject *self, PyObject *const *args, Py_ssize_t nargs, PyObject *kwnames)
{
PyObject *return_value = NULL;
#if defined(Py_BUILD_CORE) && !defined(Py_BUILD_CORE_MODULE)
@ -629,7 +629,7 @@ bytearray_translate(PyByteArrayObject *self, PyObject *const *args, Py_ssize_t n
}
deletechars = args[1];
skip_optional_pos:
return_value = bytearray_translate_impl(self, table, deletechars);
return_value = bytearray_translate_impl((PyByteArrayObject *)self, table, deletechars);
exit:
return return_value;
@ -704,7 +704,7 @@ bytearray_replace_impl(PyByteArrayObject *self, Py_buffer *old,
Py_buffer *new, Py_ssize_t count);
static PyObject *
bytearray_replace(PyByteArrayObject *self, PyObject *const *args, Py_ssize_t nargs)
bytearray_replace(PyObject *self, PyObject *const *args, Py_ssize_t nargs)
{
PyObject *return_value = NULL;
Py_buffer old = {NULL, NULL};
@ -736,7 +736,7 @@ bytearray_replace(PyByteArrayObject *self, PyObject *const *args, Py_ssize_t nar
count = ival;
}
skip_optional:
return_value = bytearray_replace_impl(self, &old, &new, count);
return_value = bytearray_replace_impl((PyByteArrayObject *)self, &old, &new, count);
exit:
/* Cleanup for old */
@ -773,7 +773,7 @@ bytearray_split_impl(PyByteArrayObject *self, PyObject *sep,
Py_ssize_t maxsplit);
static PyObject *
bytearray_split(PyByteArrayObject *self, PyObject *const *args, Py_ssize_t nargs, PyObject *kwnames)
bytearray_split(PyObject *self, PyObject *const *args, Py_ssize_t nargs, PyObject *kwnames)
{
PyObject *return_value = NULL;
#if defined(Py_BUILD_CORE) && !defined(Py_BUILD_CORE_MODULE)
@ -833,7 +833,7 @@ bytearray_split(PyByteArrayObject *self, PyObject *const *args, Py_ssize_t nargs
maxsplit = ival;
}
skip_optional_pos:
return_value = bytearray_split_impl(self, sep, maxsplit);
return_value = bytearray_split_impl((PyByteArrayObject *)self, sep, maxsplit);
exit:
return return_value;
@ -896,7 +896,7 @@ bytearray_rsplit_impl(PyByteArrayObject *self, PyObject *sep,
Py_ssize_t maxsplit);
static PyObject *
bytearray_rsplit(PyByteArrayObject *self, PyObject *const *args, Py_ssize_t nargs, PyObject *kwnames)
bytearray_rsplit(PyObject *self, PyObject *const *args, Py_ssize_t nargs, PyObject *kwnames)
{
PyObject *return_value = NULL;
#if defined(Py_BUILD_CORE) && !defined(Py_BUILD_CORE_MODULE)
@ -956,7 +956,7 @@ bytearray_rsplit(PyByteArrayObject *self, PyObject *const *args, Py_ssize_t narg
maxsplit = ival;
}
skip_optional_pos:
return_value = bytearray_rsplit_impl(self, sep, maxsplit);
return_value = bytearray_rsplit_impl((PyByteArrayObject *)self, sep, maxsplit);
exit:
return return_value;
@ -975,9 +975,9 @@ static PyObject *
bytearray_reverse_impl(PyByteArrayObject *self);
static PyObject *
bytearray_reverse(PyByteArrayObject *self, PyObject *Py_UNUSED(ignored))
bytearray_reverse(PyObject *self, PyObject *Py_UNUSED(ignored))
{
return bytearray_reverse_impl(self);
return bytearray_reverse_impl((PyByteArrayObject *)self);
}
PyDoc_STRVAR(bytearray_insert__doc__,
@ -998,7 +998,7 @@ static PyObject *
bytearray_insert_impl(PyByteArrayObject *self, Py_ssize_t index, int item);
static PyObject *
bytearray_insert(PyByteArrayObject *self, PyObject *const *args, Py_ssize_t nargs)
bytearray_insert(PyObject *self, PyObject *const *args, Py_ssize_t nargs)
{
PyObject *return_value = NULL;
Py_ssize_t index;
@ -1022,7 +1022,7 @@ bytearray_insert(PyByteArrayObject *self, PyObject *const *args, Py_ssize_t narg
if (!_getbytevalue(args[1], &item)) {
goto exit;
}
return_value = bytearray_insert_impl(self, index, item);
return_value = bytearray_insert_impl((PyByteArrayObject *)self, index, item);
exit:
return return_value;
@ -1044,7 +1044,7 @@ static PyObject *
bytearray_append_impl(PyByteArrayObject *self, int item);
static PyObject *
bytearray_append(PyByteArrayObject *self, PyObject *arg)
bytearray_append(PyObject *self, PyObject *arg)
{
PyObject *return_value = NULL;
int item;
@ -1052,7 +1052,7 @@ bytearray_append(PyByteArrayObject *self, PyObject *arg)
if (!_getbytevalue(arg, &item)) {
goto exit;
}
return_value = bytearray_append_impl(self, item);
return_value = bytearray_append_impl((PyByteArrayObject *)self, item);
exit:
return return_value;
@ -1089,7 +1089,7 @@ static PyObject *
bytearray_pop_impl(PyByteArrayObject *self, Py_ssize_t index);
static PyObject *
bytearray_pop(PyByteArrayObject *self, PyObject *const *args, Py_ssize_t nargs)
bytearray_pop(PyObject *self, PyObject *const *args, Py_ssize_t nargs)
{
PyObject *return_value = NULL;
Py_ssize_t index = -1;
@ -1113,7 +1113,7 @@ bytearray_pop(PyByteArrayObject *self, PyObject *const *args, Py_ssize_t nargs)
index = ival;
}
skip_optional:
return_value = bytearray_pop_impl(self, index);
return_value = bytearray_pop_impl((PyByteArrayObject *)self, index);
exit:
return return_value;
@ -1135,7 +1135,7 @@ static PyObject *
bytearray_remove_impl(PyByteArrayObject *self, int value);
static PyObject *
bytearray_remove(PyByteArrayObject *self, PyObject *arg)
bytearray_remove(PyObject *self, PyObject *arg)
{
PyObject *return_value = NULL;
int value;
@ -1143,7 +1143,7 @@ bytearray_remove(PyByteArrayObject *self, PyObject *arg)
if (!_getbytevalue(arg, &value)) {
goto exit;
}
return_value = bytearray_remove_impl(self, value);
return_value = bytearray_remove_impl((PyByteArrayObject *)self, value);
exit:
return return_value;
@ -1164,7 +1164,7 @@ static PyObject *
bytearray_strip_impl(PyByteArrayObject *self, PyObject *bytes);
static PyObject *
bytearray_strip(PyByteArrayObject *self, PyObject *const *args, Py_ssize_t nargs)
bytearray_strip(PyObject *self, PyObject *const *args, Py_ssize_t nargs)
{
PyObject *return_value = NULL;
PyObject *bytes = Py_None;
@ -1177,7 +1177,7 @@ bytearray_strip(PyByteArrayObject *self, PyObject *const *args, Py_ssize_t nargs
}
bytes = args[0];
skip_optional:
return_value = bytearray_strip_impl(self, bytes);
return_value = bytearray_strip_impl((PyByteArrayObject *)self, bytes);
exit:
return return_value;
@ -1198,7 +1198,7 @@ static PyObject *
bytearray_lstrip_impl(PyByteArrayObject *self, PyObject *bytes);
static PyObject *
bytearray_lstrip(PyByteArrayObject *self, PyObject *const *args, Py_ssize_t nargs)
bytearray_lstrip(PyObject *self, PyObject *const *args, Py_ssize_t nargs)
{
PyObject *return_value = NULL;
PyObject *bytes = Py_None;
@ -1211,7 +1211,7 @@ bytearray_lstrip(PyByteArrayObject *self, PyObject *const *args, Py_ssize_t narg
}
bytes = args[0];
skip_optional:
return_value = bytearray_lstrip_impl(self, bytes);
return_value = bytearray_lstrip_impl((PyByteArrayObject *)self, bytes);
exit:
return return_value;
@ -1232,7 +1232,7 @@ static PyObject *
bytearray_rstrip_impl(PyByteArrayObject *self, PyObject *bytes);
static PyObject *
bytearray_rstrip(PyByteArrayObject *self, PyObject *const *args, Py_ssize_t nargs)
bytearray_rstrip(PyObject *self, PyObject *const *args, Py_ssize_t nargs)
{
PyObject *return_value = NULL;
PyObject *bytes = Py_None;
@ -1245,7 +1245,7 @@ bytearray_rstrip(PyByteArrayObject *self, PyObject *const *args, Py_ssize_t narg
}
bytes = args[0];
skip_optional:
return_value = bytearray_rstrip_impl(self, bytes);
return_value = bytearray_rstrip_impl((PyByteArrayObject *)self, bytes);
exit:
return return_value;
@ -1274,7 +1274,7 @@ bytearray_decode_impl(PyByteArrayObject *self, const char *encoding,
const char *errors);
static PyObject *
bytearray_decode(PyByteArrayObject *self, PyObject *const *args, Py_ssize_t nargs, PyObject *kwnames)
bytearray_decode(PyObject *self, PyObject *const *args, Py_ssize_t nargs, PyObject *kwnames)
{
PyObject *return_value = NULL;
#if defined(Py_BUILD_CORE) && !defined(Py_BUILD_CORE_MODULE)
@ -1347,7 +1347,7 @@ bytearray_decode(PyByteArrayObject *self, PyObject *const *args, Py_ssize_t narg
goto exit;
}
skip_optional_pos:
return_value = bytearray_decode_impl(self, encoding, errors);
return_value = bytearray_decode_impl((PyByteArrayObject *)self, encoding, errors);
exit:
return return_value;
@ -1382,7 +1382,7 @@ static PyObject *
bytearray_splitlines_impl(PyByteArrayObject *self, int keepends);
static PyObject *
bytearray_splitlines(PyByteArrayObject *self, PyObject *const *args, Py_ssize_t nargs, PyObject *kwnames)
bytearray_splitlines(PyObject *self, PyObject *const *args, Py_ssize_t nargs, PyObject *kwnames)
{
PyObject *return_value = NULL;
#if defined(Py_BUILD_CORE) && !defined(Py_BUILD_CORE_MODULE)
@ -1427,7 +1427,7 @@ bytearray_splitlines(PyByteArrayObject *self, PyObject *const *args, Py_ssize_t
goto exit;
}
skip_optional_pos:
return_value = bytearray_splitlines_impl(self, keepends);
return_value = bytearray_splitlines_impl((PyByteArrayObject *)self, keepends);
exit:
return return_value;
@ -1495,7 +1495,7 @@ static PyObject *
bytearray_hex_impl(PyByteArrayObject *self, PyObject *sep, int bytes_per_sep);
static PyObject *
bytearray_hex(PyByteArrayObject *self, PyObject *const *args, Py_ssize_t nargs, PyObject *kwnames)
bytearray_hex(PyObject *self, PyObject *const *args, Py_ssize_t nargs, PyObject *kwnames)
{
PyObject *return_value = NULL;
#if defined(Py_BUILD_CORE) && !defined(Py_BUILD_CORE_MODULE)
@ -1547,7 +1547,7 @@ bytearray_hex(PyByteArrayObject *self, PyObject *const *args, Py_ssize_t nargs,
goto exit;
}
skip_optional_pos:
return_value = bytearray_hex_impl(self, sep, bytes_per_sep);
return_value = bytearray_hex_impl((PyByteArrayObject *)self, sep, bytes_per_sep);
exit:
return return_value;
@ -1566,9 +1566,9 @@ static PyObject *
bytearray_reduce_impl(PyByteArrayObject *self);
static PyObject *
bytearray_reduce(PyByteArrayObject *self, PyObject *Py_UNUSED(ignored))
bytearray_reduce(PyObject *self, PyObject *Py_UNUSED(ignored))
{
return bytearray_reduce_impl(self);
return bytearray_reduce_impl((PyByteArrayObject *)self);
}
PyDoc_STRVAR(bytearray_reduce_ex__doc__,
@ -1584,7 +1584,7 @@ static PyObject *
bytearray_reduce_ex_impl(PyByteArrayObject *self, int proto);
static PyObject *
bytearray_reduce_ex(PyByteArrayObject *self, PyObject *const *args, Py_ssize_t nargs)
bytearray_reduce_ex(PyObject *self, PyObject *const *args, Py_ssize_t nargs)
{
PyObject *return_value = NULL;
int proto = 0;
@ -1600,7 +1600,7 @@ bytearray_reduce_ex(PyByteArrayObject *self, PyObject *const *args, Py_ssize_t n
goto exit;
}
skip_optional:
return_value = bytearray_reduce_ex_impl(self, proto);
return_value = bytearray_reduce_ex_impl((PyByteArrayObject *)self, proto);
exit:
return return_value;
@ -1619,8 +1619,8 @@ static PyObject *
bytearray_sizeof_impl(PyByteArrayObject *self);
static PyObject *
bytearray_sizeof(PyByteArrayObject *self, PyObject *Py_UNUSED(ignored))
bytearray_sizeof(PyObject *self, PyObject *Py_UNUSED(ignored))
{
return bytearray_sizeof_impl(self);
return bytearray_sizeof_impl((PyByteArrayObject *)self);
}
/*[clinic end generated code: output=4488e38e7ffcc6ec input=a9049054013a1b77]*/
/*[clinic end generated code: output=bc8bec8514102bf3 input=a9049054013a1b77]*/

View file

@ -22,9 +22,9 @@ static PyObject *
bytes___bytes___impl(PyBytesObject *self);
static PyObject *
bytes___bytes__(PyBytesObject *self, PyObject *Py_UNUSED(ignored))
bytes___bytes__(PyObject *self, PyObject *Py_UNUSED(ignored))
{
return bytes___bytes___impl(self);
return bytes___bytes___impl((PyBytesObject *)self);
}
PyDoc_STRVAR(bytes_split__doc__,
@ -48,7 +48,7 @@ static PyObject *
bytes_split_impl(PyBytesObject *self, PyObject *sep, Py_ssize_t maxsplit);
static PyObject *
bytes_split(PyBytesObject *self, PyObject *const *args, Py_ssize_t nargs, PyObject *kwnames)
bytes_split(PyObject *self, PyObject *const *args, Py_ssize_t nargs, PyObject *kwnames)
{
PyObject *return_value = NULL;
#if defined(Py_BUILD_CORE) && !defined(Py_BUILD_CORE_MODULE)
@ -108,7 +108,7 @@ bytes_split(PyBytesObject *self, PyObject *const *args, Py_ssize_t nargs, PyObje
maxsplit = ival;
}
skip_optional_pos:
return_value = bytes_split_impl(self, sep, maxsplit);
return_value = bytes_split_impl((PyBytesObject *)self, sep, maxsplit);
exit:
return return_value;
@ -134,7 +134,7 @@ static PyObject *
bytes_partition_impl(PyBytesObject *self, Py_buffer *sep);
static PyObject *
bytes_partition(PyBytesObject *self, PyObject *arg)
bytes_partition(PyObject *self, PyObject *arg)
{
PyObject *return_value = NULL;
Py_buffer sep = {NULL, NULL};
@ -142,7 +142,7 @@ bytes_partition(PyBytesObject *self, PyObject *arg)
if (PyObject_GetBuffer(arg, &sep, PyBUF_SIMPLE) != 0) {
goto exit;
}
return_value = bytes_partition_impl(self, &sep);
return_value = bytes_partition_impl((PyBytesObject *)self, &sep);
exit:
/* Cleanup for sep */
@ -173,7 +173,7 @@ static PyObject *
bytes_rpartition_impl(PyBytesObject *self, Py_buffer *sep);
static PyObject *
bytes_rpartition(PyBytesObject *self, PyObject *arg)
bytes_rpartition(PyObject *self, PyObject *arg)
{
PyObject *return_value = NULL;
Py_buffer sep = {NULL, NULL};
@ -181,7 +181,7 @@ bytes_rpartition(PyBytesObject *self, PyObject *arg)
if (PyObject_GetBuffer(arg, &sep, PyBUF_SIMPLE) != 0) {
goto exit;
}
return_value = bytes_rpartition_impl(self, &sep);
return_value = bytes_rpartition_impl((PyBytesObject *)self, &sep);
exit:
/* Cleanup for sep */
@ -215,7 +215,7 @@ static PyObject *
bytes_rsplit_impl(PyBytesObject *self, PyObject *sep, Py_ssize_t maxsplit);
static PyObject *
bytes_rsplit(PyBytesObject *self, PyObject *const *args, Py_ssize_t nargs, PyObject *kwnames)
bytes_rsplit(PyObject *self, PyObject *const *args, Py_ssize_t nargs, PyObject *kwnames)
{
PyObject *return_value = NULL;
#if defined(Py_BUILD_CORE) && !defined(Py_BUILD_CORE_MODULE)
@ -275,7 +275,7 @@ bytes_rsplit(PyBytesObject *self, PyObject *const *args, Py_ssize_t nargs, PyObj
maxsplit = ival;
}
skip_optional_pos:
return_value = bytes_rsplit_impl(self, sep, maxsplit);
return_value = bytes_rsplit_impl((PyBytesObject *)self, sep, maxsplit);
exit:
return return_value;
@ -317,7 +317,7 @@ bytes_find_impl(PyBytesObject *self, PyObject *sub, Py_ssize_t start,
Py_ssize_t end);
static PyObject *
bytes_find(PyBytesObject *self, PyObject *const *args, Py_ssize_t nargs)
bytes_find(PyObject *self, PyObject *const *args, Py_ssize_t nargs)
{
PyObject *return_value = NULL;
PyObject *sub;
@ -341,7 +341,7 @@ bytes_find(PyBytesObject *self, PyObject *const *args, Py_ssize_t nargs)
goto exit;
}
skip_optional:
return_value = bytes_find_impl(self, sub, start, end);
return_value = bytes_find_impl((PyBytesObject *)self, sub, start, end);
exit:
return return_value;
@ -368,7 +368,7 @@ bytes_index_impl(PyBytesObject *self, PyObject *sub, Py_ssize_t start,
Py_ssize_t end);
static PyObject *
bytes_index(PyBytesObject *self, PyObject *const *args, Py_ssize_t nargs)
bytes_index(PyObject *self, PyObject *const *args, Py_ssize_t nargs)
{
PyObject *return_value = NULL;
PyObject *sub;
@ -392,7 +392,7 @@ bytes_index(PyBytesObject *self, PyObject *const *args, Py_ssize_t nargs)
goto exit;
}
skip_optional:
return_value = bytes_index_impl(self, sub, start, end);
return_value = bytes_index_impl((PyBytesObject *)self, sub, start, end);
exit:
return return_value;
@ -419,7 +419,7 @@ bytes_rfind_impl(PyBytesObject *self, PyObject *sub, Py_ssize_t start,
Py_ssize_t end);
static PyObject *
bytes_rfind(PyBytesObject *self, PyObject *const *args, Py_ssize_t nargs)
bytes_rfind(PyObject *self, PyObject *const *args, Py_ssize_t nargs)
{
PyObject *return_value = NULL;
PyObject *sub;
@ -443,7 +443,7 @@ bytes_rfind(PyBytesObject *self, PyObject *const *args, Py_ssize_t nargs)
goto exit;
}
skip_optional:
return_value = bytes_rfind_impl(self, sub, start, end);
return_value = bytes_rfind_impl((PyBytesObject *)self, sub, start, end);
exit:
return return_value;
@ -470,7 +470,7 @@ bytes_rindex_impl(PyBytesObject *self, PyObject *sub, Py_ssize_t start,
Py_ssize_t end);
static PyObject *
bytes_rindex(PyBytesObject *self, PyObject *const *args, Py_ssize_t nargs)
bytes_rindex(PyObject *self, PyObject *const *args, Py_ssize_t nargs)
{
PyObject *return_value = NULL;
PyObject *sub;
@ -494,7 +494,7 @@ bytes_rindex(PyBytesObject *self, PyObject *const *args, Py_ssize_t nargs)
goto exit;
}
skip_optional:
return_value = bytes_rindex_impl(self, sub, start, end);
return_value = bytes_rindex_impl((PyBytesObject *)self, sub, start, end);
exit:
return return_value;
@ -515,7 +515,7 @@ static PyObject *
bytes_strip_impl(PyBytesObject *self, PyObject *bytes);
static PyObject *
bytes_strip(PyBytesObject *self, PyObject *const *args, Py_ssize_t nargs)
bytes_strip(PyObject *self, PyObject *const *args, Py_ssize_t nargs)
{
PyObject *return_value = NULL;
PyObject *bytes = Py_None;
@ -528,7 +528,7 @@ bytes_strip(PyBytesObject *self, PyObject *const *args, Py_ssize_t nargs)
}
bytes = args[0];
skip_optional:
return_value = bytes_strip_impl(self, bytes);
return_value = bytes_strip_impl((PyBytesObject *)self, bytes);
exit:
return return_value;
@ -549,7 +549,7 @@ static PyObject *
bytes_lstrip_impl(PyBytesObject *self, PyObject *bytes);
static PyObject *
bytes_lstrip(PyBytesObject *self, PyObject *const *args, Py_ssize_t nargs)
bytes_lstrip(PyObject *self, PyObject *const *args, Py_ssize_t nargs)
{
PyObject *return_value = NULL;
PyObject *bytes = Py_None;
@ -562,7 +562,7 @@ bytes_lstrip(PyBytesObject *self, PyObject *const *args, Py_ssize_t nargs)
}
bytes = args[0];
skip_optional:
return_value = bytes_lstrip_impl(self, bytes);
return_value = bytes_lstrip_impl((PyBytesObject *)self, bytes);
exit:
return return_value;
@ -583,7 +583,7 @@ static PyObject *
bytes_rstrip_impl(PyBytesObject *self, PyObject *bytes);
static PyObject *
bytes_rstrip(PyBytesObject *self, PyObject *const *args, Py_ssize_t nargs)
bytes_rstrip(PyObject *self, PyObject *const *args, Py_ssize_t nargs)
{
PyObject *return_value = NULL;
PyObject *bytes = Py_None;
@ -596,7 +596,7 @@ bytes_rstrip(PyBytesObject *self, PyObject *const *args, Py_ssize_t nargs)
}
bytes = args[0];
skip_optional:
return_value = bytes_rstrip_impl(self, bytes);
return_value = bytes_rstrip_impl((PyBytesObject *)self, bytes);
exit:
return return_value;
@ -621,7 +621,7 @@ bytes_count_impl(PyBytesObject *self, PyObject *sub, Py_ssize_t start,
Py_ssize_t end);
static PyObject *
bytes_count(PyBytesObject *self, PyObject *const *args, Py_ssize_t nargs)
bytes_count(PyObject *self, PyObject *const *args, Py_ssize_t nargs)
{
PyObject *return_value = NULL;
PyObject *sub;
@ -645,7 +645,7 @@ bytes_count(PyBytesObject *self, PyObject *const *args, Py_ssize_t nargs)
goto exit;
}
skip_optional:
return_value = bytes_count_impl(self, sub, start, end);
return_value = bytes_count_impl((PyBytesObject *)self, sub, start, end);
exit:
return return_value;
@ -671,7 +671,7 @@ bytes_translate_impl(PyBytesObject *self, PyObject *table,
PyObject *deletechars);
static PyObject *
bytes_translate(PyBytesObject *self, PyObject *const *args, Py_ssize_t nargs, PyObject *kwnames)
bytes_translate(PyObject *self, PyObject *const *args, Py_ssize_t nargs, PyObject *kwnames)
{
PyObject *return_value = NULL;
#if defined(Py_BUILD_CORE) && !defined(Py_BUILD_CORE_MODULE)
@ -715,7 +715,7 @@ bytes_translate(PyBytesObject *self, PyObject *const *args, Py_ssize_t nargs, Py
}
deletechars = args[1];
skip_optional_pos:
return_value = bytes_translate_impl(self, table, deletechars);
return_value = bytes_translate_impl((PyBytesObject *)self, table, deletechars);
exit:
return return_value;
@ -790,7 +790,7 @@ bytes_replace_impl(PyBytesObject *self, Py_buffer *old, Py_buffer *new,
Py_ssize_t count);
static PyObject *
bytes_replace(PyBytesObject *self, PyObject *const *args, Py_ssize_t nargs)
bytes_replace(PyObject *self, PyObject *const *args, Py_ssize_t nargs)
{
PyObject *return_value = NULL;
Py_buffer old = {NULL, NULL};
@ -822,7 +822,7 @@ bytes_replace(PyBytesObject *self, PyObject *const *args, Py_ssize_t nargs)
count = ival;
}
skip_optional:
return_value = bytes_replace_impl(self, &old, &new, count);
return_value = bytes_replace_impl((PyBytesObject *)self, &old, &new, count);
exit:
/* Cleanup for old */
@ -853,7 +853,7 @@ static PyObject *
bytes_removeprefix_impl(PyBytesObject *self, Py_buffer *prefix);
static PyObject *
bytes_removeprefix(PyBytesObject *self, PyObject *arg)
bytes_removeprefix(PyObject *self, PyObject *arg)
{
PyObject *return_value = NULL;
Py_buffer prefix = {NULL, NULL};
@ -861,7 +861,7 @@ bytes_removeprefix(PyBytesObject *self, PyObject *arg)
if (PyObject_GetBuffer(arg, &prefix, PyBUF_SIMPLE) != 0) {
goto exit;
}
return_value = bytes_removeprefix_impl(self, &prefix);
return_value = bytes_removeprefix_impl((PyBytesObject *)self, &prefix);
exit:
/* Cleanup for prefix */
@ -889,7 +889,7 @@ static PyObject *
bytes_removesuffix_impl(PyBytesObject *self, Py_buffer *suffix);
static PyObject *
bytes_removesuffix(PyBytesObject *self, PyObject *arg)
bytes_removesuffix(PyObject *self, PyObject *arg)
{
PyObject *return_value = NULL;
Py_buffer suffix = {NULL, NULL};
@ -897,7 +897,7 @@ bytes_removesuffix(PyBytesObject *self, PyObject *arg)
if (PyObject_GetBuffer(arg, &suffix, PyBUF_SIMPLE) != 0) {
goto exit;
}
return_value = bytes_removesuffix_impl(self, &suffix);
return_value = bytes_removesuffix_impl((PyBytesObject *)self, &suffix);
exit:
/* Cleanup for suffix */
@ -929,7 +929,7 @@ bytes_startswith_impl(PyBytesObject *self, PyObject *subobj,
Py_ssize_t start, Py_ssize_t end);
static PyObject *
bytes_startswith(PyBytesObject *self, PyObject *const *args, Py_ssize_t nargs)
bytes_startswith(PyObject *self, PyObject *const *args, Py_ssize_t nargs)
{
PyObject *return_value = NULL;
PyObject *subobj;
@ -953,7 +953,7 @@ bytes_startswith(PyBytesObject *self, PyObject *const *args, Py_ssize_t nargs)
goto exit;
}
skip_optional:
return_value = bytes_startswith_impl(self, subobj, start, end);
return_value = bytes_startswith_impl((PyBytesObject *)self, subobj, start, end);
exit:
return return_value;
@ -980,7 +980,7 @@ bytes_endswith_impl(PyBytesObject *self, PyObject *subobj, Py_ssize_t start,
Py_ssize_t end);
static PyObject *
bytes_endswith(PyBytesObject *self, PyObject *const *args, Py_ssize_t nargs)
bytes_endswith(PyObject *self, PyObject *const *args, Py_ssize_t nargs)
{
PyObject *return_value = NULL;
PyObject *subobj;
@ -1004,7 +1004,7 @@ bytes_endswith(PyBytesObject *self, PyObject *const *args, Py_ssize_t nargs)
goto exit;
}
skip_optional:
return_value = bytes_endswith_impl(self, subobj, start, end);
return_value = bytes_endswith_impl((PyBytesObject *)self, subobj, start, end);
exit:
return return_value;
@ -1033,7 +1033,7 @@ bytes_decode_impl(PyBytesObject *self, const char *encoding,
const char *errors);
static PyObject *
bytes_decode(PyBytesObject *self, PyObject *const *args, Py_ssize_t nargs, PyObject *kwnames)
bytes_decode(PyObject *self, PyObject *const *args, Py_ssize_t nargs, PyObject *kwnames)
{
PyObject *return_value = NULL;
#if defined(Py_BUILD_CORE) && !defined(Py_BUILD_CORE_MODULE)
@ -1106,7 +1106,7 @@ bytes_decode(PyBytesObject *self, PyObject *const *args, Py_ssize_t nargs, PyObj
goto exit;
}
skip_optional_pos:
return_value = bytes_decode_impl(self, encoding, errors);
return_value = bytes_decode_impl((PyBytesObject *)self, encoding, errors);
exit:
return return_value;
@ -1128,7 +1128,7 @@ static PyObject *
bytes_splitlines_impl(PyBytesObject *self, int keepends);
static PyObject *
bytes_splitlines(PyBytesObject *self, PyObject *const *args, Py_ssize_t nargs, PyObject *kwnames)
bytes_splitlines(PyObject *self, PyObject *const *args, Py_ssize_t nargs, PyObject *kwnames)
{
PyObject *return_value = NULL;
#if defined(Py_BUILD_CORE) && !defined(Py_BUILD_CORE_MODULE)
@ -1173,7 +1173,7 @@ bytes_splitlines(PyBytesObject *self, PyObject *const *args, Py_ssize_t nargs, P
goto exit;
}
skip_optional_pos:
return_value = bytes_splitlines_impl(self, keepends);
return_value = bytes_splitlines_impl((PyBytesObject *)self, keepends);
exit:
return return_value;
@ -1241,7 +1241,7 @@ static PyObject *
bytes_hex_impl(PyBytesObject *self, PyObject *sep, int bytes_per_sep);
static PyObject *
bytes_hex(PyBytesObject *self, PyObject *const *args, Py_ssize_t nargs, PyObject *kwnames)
bytes_hex(PyObject *self, PyObject *const *args, Py_ssize_t nargs, PyObject *kwnames)
{
PyObject *return_value = NULL;
#if defined(Py_BUILD_CORE) && !defined(Py_BUILD_CORE_MODULE)
@ -1293,7 +1293,7 @@ bytes_hex(PyBytesObject *self, PyObject *const *args, Py_ssize_t nargs, PyObject
goto exit;
}
skip_optional_pos:
return_value = bytes_hex_impl(self, sep, bytes_per_sep);
return_value = bytes_hex_impl((PyBytesObject *)self, sep, bytes_per_sep);
exit:
return return_value;
@ -1391,4 +1391,4 @@ skip_optional_pos:
exit:
return return_value;
}
/*[clinic end generated code: output=fb7939a1983e463a input=a9049054013a1b77]*/
/*[clinic end generated code: output=96fe2d6ef9ac8f6a input=a9049054013a1b77]*/

View file

@ -16,9 +16,9 @@ static PyObject *
method___reduce___impl(PyMethodObject *self);
static PyObject *
method___reduce__(PyMethodObject *self, PyObject *Py_UNUSED(ignored))
method___reduce__(PyObject *self, PyObject *Py_UNUSED(ignored))
{
return method___reduce___impl(self);
return method___reduce___impl((PyMethodObject *)self);
}
PyDoc_STRVAR(method_new__doc__,
@ -82,4 +82,4 @@ instancemethod_new(PyTypeObject *type, PyObject *args, PyObject *kwargs)
exit:
return return_value;
}
/*[clinic end generated code: output=5a5e3f2d0726f189 input=a9049054013a1b77]*/
/*[clinic end generated code: output=ab546abf90aac94e input=a9049054013a1b77]*/

View file

@ -174,7 +174,7 @@ code_replace_impl(PyCodeObject *self, int co_argcount,
PyObject *co_exceptiontable);
static PyObject *
code_replace(PyCodeObject *self, PyObject *const *args, Py_ssize_t nargs, PyObject *kwnames)
code_replace(PyObject *self, PyObject *const *args, Py_ssize_t nargs, PyObject *kwnames)
{
PyObject *return_value = NULL;
#if defined(Py_BUILD_CORE) && !defined(Py_BUILD_CORE_MODULE)
@ -204,24 +204,24 @@ code_replace(PyCodeObject *self, PyObject *const *args, Py_ssize_t nargs, PyObje
#undef KWTUPLE
PyObject *argsbuf[18];
Py_ssize_t noptargs = nargs + (kwnames ? PyTuple_GET_SIZE(kwnames) : 0) - 0;
int co_argcount = self->co_argcount;
int co_posonlyargcount = self->co_posonlyargcount;
int co_kwonlyargcount = self->co_kwonlyargcount;
int co_nlocals = self->co_nlocals;
int co_stacksize = self->co_stacksize;
int co_flags = self->co_flags;
int co_firstlineno = self->co_firstlineno;
int co_argcount = ((PyCodeObject *)self)->co_argcount;
int co_posonlyargcount = ((PyCodeObject *)self)->co_posonlyargcount;
int co_kwonlyargcount = ((PyCodeObject *)self)->co_kwonlyargcount;
int co_nlocals = ((PyCodeObject *)self)->co_nlocals;
int co_stacksize = ((PyCodeObject *)self)->co_stacksize;
int co_flags = ((PyCodeObject *)self)->co_flags;
int co_firstlineno = ((PyCodeObject *)self)->co_firstlineno;
PyObject *co_code = NULL;
PyObject *co_consts = self->co_consts;
PyObject *co_names = self->co_names;
PyObject *co_consts = ((PyCodeObject *)self)->co_consts;
PyObject *co_names = ((PyCodeObject *)self)->co_names;
PyObject *co_varnames = NULL;
PyObject *co_freevars = NULL;
PyObject *co_cellvars = NULL;
PyObject *co_filename = self->co_filename;
PyObject *co_name = self->co_name;
PyObject *co_qualname = self->co_qualname;
PyObject *co_linetable = self->co_linetable;
PyObject *co_exceptiontable = self->co_exceptiontable;
PyObject *co_filename = ((PyCodeObject *)self)->co_filename;
PyObject *co_name = ((PyCodeObject *)self)->co_name;
PyObject *co_qualname = ((PyCodeObject *)self)->co_qualname;
PyObject *co_linetable = ((PyCodeObject *)self)->co_linetable;
PyObject *co_exceptiontable = ((PyCodeObject *)self)->co_exceptiontable;
args = _PyArg_UnpackKeywords(args, nargs, NULL, kwnames, &_parser,
/*minpos*/ 0, /*maxpos*/ 0, /*minkw*/ 0, /*varpos*/ 0, argsbuf);
@ -400,7 +400,7 @@ code_replace(PyCodeObject *self, PyObject *const *args, Py_ssize_t nargs, PyObje
}
co_exceptiontable = args[17];
skip_optional_kwonly:
return_value = code_replace_impl(self, co_argcount, co_posonlyargcount, co_kwonlyargcount, co_nlocals, co_stacksize, co_flags, co_firstlineno, co_code, co_consts, co_names, co_varnames, co_freevars, co_cellvars, co_filename, co_name, co_qualname, co_linetable, co_exceptiontable);
return_value = code_replace_impl((PyCodeObject *)self, co_argcount, co_posonlyargcount, co_kwonlyargcount, co_nlocals, co_stacksize, co_flags, co_firstlineno, co_code, co_consts, co_names, co_varnames, co_freevars, co_cellvars, co_filename, co_name, co_qualname, co_linetable, co_exceptiontable);
exit:
return return_value;
@ -421,7 +421,7 @@ static PyObject *
code__varname_from_oparg_impl(PyCodeObject *self, int oparg);
static PyObject *
code__varname_from_oparg(PyCodeObject *self, PyObject *const *args, Py_ssize_t nargs, PyObject *kwnames)
code__varname_from_oparg(PyObject *self, PyObject *const *args, Py_ssize_t nargs, PyObject *kwnames)
{
PyObject *return_value = NULL;
#if defined(Py_BUILD_CORE) && !defined(Py_BUILD_CORE_MODULE)
@ -461,9 +461,9 @@ code__varname_from_oparg(PyCodeObject *self, PyObject *const *args, Py_ssize_t n
if (oparg == -1 && PyErr_Occurred()) {
goto exit;
}
return_value = code__varname_from_oparg_impl(self, oparg);
return_value = code__varname_from_oparg_impl((PyCodeObject *)self, oparg);
exit:
return return_value;
}
/*[clinic end generated code: output=e919ea67a1bcf524 input=a9049054013a1b77]*/
/*[clinic end generated code: output=73861c79e93aaee5 input=a9049054013a1b77]*/

View file

@ -21,9 +21,9 @@ static PyObject *
complex_conjugate_impl(PyComplexObject *self);
static PyObject *
complex_conjugate(PyComplexObject *self, PyObject *Py_UNUSED(ignored))
complex_conjugate(PyObject *self, PyObject *Py_UNUSED(ignored))
{
return complex_conjugate_impl(self);
return complex_conjugate_impl((PyComplexObject *)self);
}
PyDoc_STRVAR(complex___getnewargs____doc__,
@ -38,9 +38,9 @@ static PyObject *
complex___getnewargs___impl(PyComplexObject *self);
static PyObject *
complex___getnewargs__(PyComplexObject *self, PyObject *Py_UNUSED(ignored))
complex___getnewargs__(PyObject *self, PyObject *Py_UNUSED(ignored))
{
return complex___getnewargs___impl(self);
return complex___getnewargs___impl((PyComplexObject *)self);
}
PyDoc_STRVAR(complex___format____doc__,
@ -56,7 +56,7 @@ static PyObject *
complex___format___impl(PyComplexObject *self, PyObject *format_spec);
static PyObject *
complex___format__(PyComplexObject *self, PyObject *arg)
complex___format__(PyObject *self, PyObject *arg)
{
PyObject *return_value = NULL;
PyObject *format_spec;
@ -66,7 +66,7 @@ complex___format__(PyComplexObject *self, PyObject *arg)
goto exit;
}
format_spec = arg;
return_value = complex___format___impl(self, format_spec);
return_value = complex___format___impl((PyComplexObject *)self, format_spec);
exit:
return return_value;
@ -85,9 +85,9 @@ static PyObject *
complex___complex___impl(PyComplexObject *self);
static PyObject *
complex___complex__(PyComplexObject *self, PyObject *Py_UNUSED(ignored))
complex___complex__(PyObject *self, PyObject *Py_UNUSED(ignored))
{
return complex___complex___impl(self);
return complex___complex___impl((PyComplexObject *)self);
}
PyDoc_STRVAR(complex_new__doc__,
@ -170,4 +170,4 @@ PyDoc_STRVAR(complex_from_number__doc__,
#define COMPLEX_FROM_NUMBER_METHODDEF \
{"from_number", (PyCFunction)complex_from_number, METH_O|METH_CLASS, complex_from_number__doc__},
/*[clinic end generated code: output=8c49a41c5a7f0aee input=a9049054013a1b77]*/
/*[clinic end generated code: output=252cddef7f9169a0 input=a9049054013a1b77]*/

View file

@ -52,9 +52,9 @@ static PyObject *
dict_copy_impl(PyDictObject *self);
static PyObject *
dict_copy(PyDictObject *self, PyObject *Py_UNUSED(ignored))
dict_copy(PyObject *self, PyObject *Py_UNUSED(ignored))
{
return dict_copy_impl(self);
return dict_copy_impl((PyDictObject *)self);
}
PyDoc_STRVAR(dict___contains____doc__,
@ -79,7 +79,7 @@ static PyObject *
dict_get_impl(PyDictObject *self, PyObject *key, PyObject *default_value);
static PyObject *
dict_get(PyDictObject *self, PyObject *const *args, Py_ssize_t nargs)
dict_get(PyObject *self, PyObject *const *args, Py_ssize_t nargs)
{
PyObject *return_value = NULL;
PyObject *key;
@ -95,7 +95,7 @@ dict_get(PyDictObject *self, PyObject *const *args, Py_ssize_t nargs)
default_value = args[1];
skip_optional:
Py_BEGIN_CRITICAL_SECTION(self);
return_value = dict_get_impl(self, key, default_value);
return_value = dict_get_impl((PyDictObject *)self, key, default_value);
Py_END_CRITICAL_SECTION();
exit:
@ -118,7 +118,7 @@ dict_setdefault_impl(PyDictObject *self, PyObject *key,
PyObject *default_value);
static PyObject *
dict_setdefault(PyDictObject *self, PyObject *const *args, Py_ssize_t nargs)
dict_setdefault(PyObject *self, PyObject *const *args, Py_ssize_t nargs)
{
PyObject *return_value = NULL;
PyObject *key;
@ -134,7 +134,7 @@ dict_setdefault(PyDictObject *self, PyObject *const *args, Py_ssize_t nargs)
default_value = args[1];
skip_optional:
Py_BEGIN_CRITICAL_SECTION(self);
return_value = dict_setdefault_impl(self, key, default_value);
return_value = dict_setdefault_impl((PyDictObject *)self, key, default_value);
Py_END_CRITICAL_SECTION();
exit:
@ -154,9 +154,9 @@ static PyObject *
dict_clear_impl(PyDictObject *self);
static PyObject *
dict_clear(PyDictObject *self, PyObject *Py_UNUSED(ignored))
dict_clear(PyObject *self, PyObject *Py_UNUSED(ignored))
{
return dict_clear_impl(self);
return dict_clear_impl((PyDictObject *)self);
}
PyDoc_STRVAR(dict_pop__doc__,
@ -175,7 +175,7 @@ static PyObject *
dict_pop_impl(PyDictObject *self, PyObject *key, PyObject *default_value);
static PyObject *
dict_pop(PyDictObject *self, PyObject *const *args, Py_ssize_t nargs)
dict_pop(PyObject *self, PyObject *const *args, Py_ssize_t nargs)
{
PyObject *return_value = NULL;
PyObject *key;
@ -190,7 +190,7 @@ dict_pop(PyDictObject *self, PyObject *const *args, Py_ssize_t nargs)
}
default_value = args[1];
skip_optional:
return_value = dict_pop_impl(self, key, default_value);
return_value = dict_pop_impl((PyDictObject *)self, key, default_value);
exit:
return return_value;
@ -212,12 +212,12 @@ static PyObject *
dict_popitem_impl(PyDictObject *self);
static PyObject *
dict_popitem(PyDictObject *self, PyObject *Py_UNUSED(ignored))
dict_popitem(PyObject *self, PyObject *Py_UNUSED(ignored))
{
PyObject *return_value = NULL;
Py_BEGIN_CRITICAL_SECTION(self);
return_value = dict_popitem_impl(self);
return_value = dict_popitem_impl((PyDictObject *)self);
Py_END_CRITICAL_SECTION();
return return_value;
@ -236,9 +236,9 @@ static PyObject *
dict___sizeof___impl(PyDictObject *self);
static PyObject *
dict___sizeof__(PyDictObject *self, PyObject *Py_UNUSED(ignored))
dict___sizeof__(PyObject *self, PyObject *Py_UNUSED(ignored))
{
return dict___sizeof___impl(self);
return dict___sizeof___impl((PyDictObject *)self);
}
PyDoc_STRVAR(dict___reversed____doc__,
@ -254,9 +254,9 @@ static PyObject *
dict___reversed___impl(PyDictObject *self);
static PyObject *
dict___reversed__(PyDictObject *self, PyObject *Py_UNUSED(ignored))
dict___reversed__(PyObject *self, PyObject *Py_UNUSED(ignored))
{
return dict___reversed___impl(self);
return dict___reversed___impl((PyDictObject *)self);
}
PyDoc_STRVAR(dict_keys__doc__,
@ -272,9 +272,9 @@ static PyObject *
dict_keys_impl(PyDictObject *self);
static PyObject *
dict_keys(PyDictObject *self, PyObject *Py_UNUSED(ignored))
dict_keys(PyObject *self, PyObject *Py_UNUSED(ignored))
{
return dict_keys_impl(self);
return dict_keys_impl((PyDictObject *)self);
}
PyDoc_STRVAR(dict_items__doc__,
@ -290,9 +290,9 @@ static PyObject *
dict_items_impl(PyDictObject *self);
static PyObject *
dict_items(PyDictObject *self, PyObject *Py_UNUSED(ignored))
dict_items(PyObject *self, PyObject *Py_UNUSED(ignored))
{
return dict_items_impl(self);
return dict_items_impl((PyDictObject *)self);
}
PyDoc_STRVAR(dict_values__doc__,
@ -308,8 +308,8 @@ static PyObject *
dict_values_impl(PyDictObject *self);
static PyObject *
dict_values(PyDictObject *self, PyObject *Py_UNUSED(ignored))
dict_values(PyObject *self, PyObject *Py_UNUSED(ignored))
{
return dict_values_impl(self);
return dict_values_impl((PyDictObject *)self);
}
/*[clinic end generated code: output=f3dd5f3fb8122aef input=a9049054013a1b77]*/
/*[clinic end generated code: output=4956c5b276ea652f input=a9049054013a1b77]*/

View file

@ -23,7 +23,7 @@ static PyObject *
list_insert_impl(PyListObject *self, Py_ssize_t index, PyObject *object);
static PyObject *
list_insert(PyListObject *self, PyObject *const *args, Py_ssize_t nargs)
list_insert(PyObject *self, PyObject *const *args, Py_ssize_t nargs)
{
PyObject *return_value = NULL;
Py_ssize_t index;
@ -46,7 +46,7 @@ list_insert(PyListObject *self, PyObject *const *args, Py_ssize_t nargs)
}
object = args[1];
Py_BEGIN_CRITICAL_SECTION(self);
return_value = list_insert_impl(self, index, object);
return_value = list_insert_impl((PyListObject *)self, index, object);
Py_END_CRITICAL_SECTION();
exit:
@ -66,12 +66,12 @@ static PyObject *
py_list_clear_impl(PyListObject *self);
static PyObject *
py_list_clear(PyListObject *self, PyObject *Py_UNUSED(ignored))
py_list_clear(PyObject *self, PyObject *Py_UNUSED(ignored))
{
PyObject *return_value = NULL;
Py_BEGIN_CRITICAL_SECTION(self);
return_value = py_list_clear_impl(self);
return_value = py_list_clear_impl((PyListObject *)self);
Py_END_CRITICAL_SECTION();
return return_value;
@ -90,12 +90,12 @@ static PyObject *
list_copy_impl(PyListObject *self);
static PyObject *
list_copy(PyListObject *self, PyObject *Py_UNUSED(ignored))
list_copy(PyObject *self, PyObject *Py_UNUSED(ignored))
{
PyObject *return_value = NULL;
Py_BEGIN_CRITICAL_SECTION(self);
return_value = list_copy_impl(self);
return_value = list_copy_impl((PyListObject *)self);
Py_END_CRITICAL_SECTION();
return return_value;
@ -119,7 +119,7 @@ list_append(PyListObject *self, PyObject *object)
PyObject *return_value = NULL;
Py_BEGIN_CRITICAL_SECTION(self);
return_value = list_append_impl(self, object);
return_value = list_append_impl((PyListObject *)self, object);
Py_END_CRITICAL_SECTION();
return return_value;
@ -149,7 +149,7 @@ static PyObject *
list_pop_impl(PyListObject *self, Py_ssize_t index);
static PyObject *
list_pop(PyListObject *self, PyObject *const *args, Py_ssize_t nargs)
list_pop(PyObject *self, PyObject *const *args, Py_ssize_t nargs)
{
PyObject *return_value = NULL;
Py_ssize_t index = -1;
@ -174,7 +174,7 @@ list_pop(PyListObject *self, PyObject *const *args, Py_ssize_t nargs)
}
skip_optional:
Py_BEGIN_CRITICAL_SECTION(self);
return_value = list_pop_impl(self, index);
return_value = list_pop_impl((PyListObject *)self, index);
Py_END_CRITICAL_SECTION();
exit:
@ -202,7 +202,7 @@ static PyObject *
list_sort_impl(PyListObject *self, PyObject *keyfunc, int reverse);
static PyObject *
list_sort(PyListObject *self, PyObject *const *args, Py_ssize_t nargs, PyObject *kwnames)
list_sort(PyObject *self, PyObject *const *args, Py_ssize_t nargs, PyObject *kwnames)
{
PyObject *return_value = NULL;
#if defined(Py_BUILD_CORE) && !defined(Py_BUILD_CORE_MODULE)
@ -255,7 +255,7 @@ list_sort(PyListObject *self, PyObject *const *args, Py_ssize_t nargs, PyObject
}
skip_optional_kwonly:
Py_BEGIN_CRITICAL_SECTION(self);
return_value = list_sort_impl(self, keyfunc, reverse);
return_value = list_sort_impl((PyListObject *)self, keyfunc, reverse);
Py_END_CRITICAL_SECTION();
exit:
@ -275,12 +275,12 @@ static PyObject *
list_reverse_impl(PyListObject *self);
static PyObject *
list_reverse(PyListObject *self, PyObject *Py_UNUSED(ignored))
list_reverse(PyObject *self, PyObject *Py_UNUSED(ignored))
{
PyObject *return_value = NULL;
Py_BEGIN_CRITICAL_SECTION(self);
return_value = list_reverse_impl(self);
return_value = list_reverse_impl((PyListObject *)self);
Py_END_CRITICAL_SECTION();
return return_value;
@ -302,7 +302,7 @@ list_index_impl(PyListObject *self, PyObject *value, Py_ssize_t start,
Py_ssize_t stop);
static PyObject *
list_index(PyListObject *self, PyObject *const *args, Py_ssize_t nargs)
list_index(PyObject *self, PyObject *const *args, Py_ssize_t nargs)
{
PyObject *return_value = NULL;
PyObject *value;
@ -326,7 +326,7 @@ list_index(PyListObject *self, PyObject *const *args, Py_ssize_t nargs)
goto exit;
}
skip_optional:
return_value = list_index_impl(self, value, start, stop);
return_value = list_index_impl((PyListObject *)self, value, start, stop);
exit:
return return_value;
@ -361,7 +361,7 @@ list_remove(PyListObject *self, PyObject *value)
PyObject *return_value = NULL;
Py_BEGIN_CRITICAL_SECTION(self);
return_value = list_remove_impl(self, value);
return_value = list_remove_impl((PyListObject *)self, value);
Py_END_CRITICAL_SECTION();
return return_value;
@ -418,9 +418,9 @@ static PyObject *
list___sizeof___impl(PyListObject *self);
static PyObject *
list___sizeof__(PyListObject *self, PyObject *Py_UNUSED(ignored))
list___sizeof__(PyObject *self, PyObject *Py_UNUSED(ignored))
{
return list___sizeof___impl(self);
return list___sizeof___impl((PyListObject *)self);
}
PyDoc_STRVAR(list___reversed____doc__,
@ -436,8 +436,8 @@ static PyObject *
list___reversed___impl(PyListObject *self);
static PyObject *
list___reversed__(PyListObject *self, PyObject *Py_UNUSED(ignored))
list___reversed__(PyObject *self, PyObject *Py_UNUSED(ignored))
{
return list___reversed___impl(self);
return list___reversed___impl((PyListObject *)self);
}
/*[clinic end generated code: output=9357151278d77ea1 input=a9049054013a1b77]*/
/*[clinic end generated code: output=35c43dc33f9ba521 input=a9049054013a1b77]*/

View file

@ -137,9 +137,9 @@ static PyObject *
memoryview_release_impl(PyMemoryViewObject *self);
static PyObject *
memoryview_release(PyMemoryViewObject *self, PyObject *Py_UNUSED(ignored))
memoryview_release(PyObject *self, PyObject *Py_UNUSED(ignored))
{
return memoryview_release_impl(self);
return memoryview_release_impl((PyMemoryViewObject *)self);
}
PyDoc_STRVAR(memoryview_cast__doc__,
@ -156,7 +156,7 @@ memoryview_cast_impl(PyMemoryViewObject *self, PyObject *format,
PyObject *shape);
static PyObject *
memoryview_cast(PyMemoryViewObject *self, PyObject *const *args, Py_ssize_t nargs, PyObject *kwnames)
memoryview_cast(PyObject *self, PyObject *const *args, Py_ssize_t nargs, PyObject *kwnames)
{
PyObject *return_value = NULL;
#if defined(Py_BUILD_CORE) && !defined(Py_BUILD_CORE_MODULE)
@ -204,7 +204,7 @@ memoryview_cast(PyMemoryViewObject *self, PyObject *const *args, Py_ssize_t narg
}
shape = args[1];
skip_optional_pos:
return_value = memoryview_cast_impl(self, format, shape);
return_value = memoryview_cast_impl((PyMemoryViewObject *)self, format, shape);
exit:
return return_value;
@ -223,9 +223,9 @@ static PyObject *
memoryview_toreadonly_impl(PyMemoryViewObject *self);
static PyObject *
memoryview_toreadonly(PyMemoryViewObject *self, PyObject *Py_UNUSED(ignored))
memoryview_toreadonly(PyObject *self, PyObject *Py_UNUSED(ignored))
{
return memoryview_toreadonly_impl(self);
return memoryview_toreadonly_impl((PyMemoryViewObject *)self);
}
PyDoc_STRVAR(memoryview_tolist__doc__,
@ -241,9 +241,9 @@ static PyObject *
memoryview_tolist_impl(PyMemoryViewObject *self);
static PyObject *
memoryview_tolist(PyMemoryViewObject *self, PyObject *Py_UNUSED(ignored))
memoryview_tolist(PyObject *self, PyObject *Py_UNUSED(ignored))
{
return memoryview_tolist_impl(self);
return memoryview_tolist_impl((PyMemoryViewObject *)self);
}
PyDoc_STRVAR(memoryview_tobytes__doc__,
@ -265,7 +265,7 @@ static PyObject *
memoryview_tobytes_impl(PyMemoryViewObject *self, const char *order);
static PyObject *
memoryview_tobytes(PyMemoryViewObject *self, PyObject *const *args, Py_ssize_t nargs, PyObject *kwnames)
memoryview_tobytes(PyObject *self, PyObject *const *args, Py_ssize_t nargs, PyObject *kwnames)
{
PyObject *return_value = NULL;
#if defined(Py_BUILD_CORE) && !defined(Py_BUILD_CORE_MODULE)
@ -324,7 +324,7 @@ memoryview_tobytes(PyMemoryViewObject *self, PyObject *const *args, Py_ssize_t n
goto exit;
}
skip_optional_pos:
return_value = memoryview_tobytes_impl(self, order);
return_value = memoryview_tobytes_impl((PyMemoryViewObject *)self, order);
exit:
return return_value;
@ -361,7 +361,7 @@ memoryview_hex_impl(PyMemoryViewObject *self, PyObject *sep,
int bytes_per_sep);
static PyObject *
memoryview_hex(PyMemoryViewObject *self, PyObject *const *args, Py_ssize_t nargs, PyObject *kwnames)
memoryview_hex(PyObject *self, PyObject *const *args, Py_ssize_t nargs, PyObject *kwnames)
{
PyObject *return_value = NULL;
#if defined(Py_BUILD_CORE) && !defined(Py_BUILD_CORE_MODULE)
@ -413,7 +413,7 @@ memoryview_hex(PyMemoryViewObject *self, PyObject *const *args, Py_ssize_t nargs
goto exit;
}
skip_optional_pos:
return_value = memoryview_hex_impl(self, sep, bytes_per_sep);
return_value = memoryview_hex_impl((PyMemoryViewObject *)self, sep, bytes_per_sep);
exit:
return return_value;
@ -444,7 +444,7 @@ memoryview_index_impl(PyMemoryViewObject *self, PyObject *value,
Py_ssize_t start, Py_ssize_t stop);
static PyObject *
memoryview_index(PyMemoryViewObject *self, PyObject *const *args, Py_ssize_t nargs)
memoryview_index(PyObject *self, PyObject *const *args, Py_ssize_t nargs)
{
PyObject *return_value = NULL;
PyObject *value;
@ -468,9 +468,9 @@ memoryview_index(PyMemoryViewObject *self, PyObject *const *args, Py_ssize_t nar
goto exit;
}
skip_optional:
return_value = memoryview_index_impl(self, value, start, stop);
return_value = memoryview_index_impl((PyMemoryViewObject *)self, value, start, stop);
exit:
return return_value;
}
/*[clinic end generated code: output=132893ef5f67ad73 input=a9049054013a1b77]*/
/*[clinic end generated code: output=2ef6c061d9c4e3dc input=a9049054013a1b77]*/

View file

@ -87,7 +87,7 @@ OrderedDict_setdefault_impl(PyODictObject *self, PyObject *key,
PyObject *default_value);
static PyObject *
OrderedDict_setdefault(PyODictObject *self, PyObject *const *args, Py_ssize_t nargs, PyObject *kwnames)
OrderedDict_setdefault(PyObject *self, PyObject *const *args, Py_ssize_t nargs, PyObject *kwnames)
{
PyObject *return_value = NULL;
#if defined(Py_BUILD_CORE) && !defined(Py_BUILD_CORE_MODULE)
@ -131,7 +131,7 @@ OrderedDict_setdefault(PyODictObject *self, PyObject *const *args, Py_ssize_t na
}
default_value = args[1];
skip_optional_pos:
return_value = OrderedDict_setdefault_impl(self, key, default_value);
return_value = OrderedDict_setdefault_impl((PyODictObject *)self, key, default_value);
exit:
return return_value;
@ -154,7 +154,7 @@ OrderedDict_pop_impl(PyODictObject *self, PyObject *key,
PyObject *default_value);
static PyObject *
OrderedDict_pop(PyODictObject *self, PyObject *const *args, Py_ssize_t nargs, PyObject *kwnames)
OrderedDict_pop(PyObject *self, PyObject *const *args, Py_ssize_t nargs, PyObject *kwnames)
{
PyObject *return_value = NULL;
#if defined(Py_BUILD_CORE) && !defined(Py_BUILD_CORE_MODULE)
@ -198,7 +198,7 @@ OrderedDict_pop(PyODictObject *self, PyObject *const *args, Py_ssize_t nargs, Py
}
default_value = args[1];
skip_optional_pos:
return_value = OrderedDict_pop_impl(self, key, default_value);
return_value = OrderedDict_pop_impl((PyODictObject *)self, key, default_value);
exit:
return return_value;
@ -219,7 +219,7 @@ static PyObject *
OrderedDict_popitem_impl(PyODictObject *self, int last);
static PyObject *
OrderedDict_popitem(PyODictObject *self, PyObject *const *args, Py_ssize_t nargs, PyObject *kwnames)
OrderedDict_popitem(PyObject *self, PyObject *const *args, Py_ssize_t nargs, PyObject *kwnames)
{
PyObject *return_value = NULL;
#if defined(Py_BUILD_CORE) && !defined(Py_BUILD_CORE_MODULE)
@ -264,7 +264,7 @@ OrderedDict_popitem(PyODictObject *self, PyObject *const *args, Py_ssize_t nargs
goto exit;
}
skip_optional_pos:
return_value = OrderedDict_popitem_impl(self, last);
return_value = OrderedDict_popitem_impl((PyODictObject *)self, last);
exit:
return return_value;
@ -285,7 +285,7 @@ static PyObject *
OrderedDict_move_to_end_impl(PyODictObject *self, PyObject *key, int last);
static PyObject *
OrderedDict_move_to_end(PyODictObject *self, PyObject *const *args, Py_ssize_t nargs, PyObject *kwnames)
OrderedDict_move_to_end(PyObject *self, PyObject *const *args, Py_ssize_t nargs, PyObject *kwnames)
{
PyObject *return_value = NULL;
#if defined(Py_BUILD_CORE) && !defined(Py_BUILD_CORE_MODULE)
@ -332,9 +332,9 @@ OrderedDict_move_to_end(PyODictObject *self, PyObject *const *args, Py_ssize_t n
goto exit;
}
skip_optional_pos:
return_value = OrderedDict_move_to_end_impl(self, key, last);
return_value = OrderedDict_move_to_end_impl((PyODictObject *)self, key, last);
exit:
return return_value;
}
/*[clinic end generated code: output=2aa6fc0567c9252c input=a9049054013a1b77]*/
/*[clinic end generated code: output=55bd390bb516e997 input=a9049054013a1b77]*/

View file

@ -19,12 +19,12 @@ static PyObject *
set_pop_impl(PySetObject *so);
static PyObject *
set_pop(PySetObject *so, PyObject *Py_UNUSED(ignored))
set_pop(PyObject *so, PyObject *Py_UNUSED(ignored))
{
PyObject *return_value = NULL;
Py_BEGIN_CRITICAL_SECTION(so);
return_value = set_pop_impl(so);
return_value = set_pop_impl((PySetObject *)so);
Py_END_CRITICAL_SECTION();
return return_value;
@ -44,7 +44,7 @@ set_update_impl(PySetObject *so, PyObject * const *others,
Py_ssize_t others_length);
static PyObject *
set_update(PySetObject *so, PyObject *const *args, Py_ssize_t nargs)
set_update(PyObject *so, PyObject *const *args, Py_ssize_t nargs)
{
PyObject *return_value = NULL;
PyObject * const *others;
@ -52,7 +52,7 @@ set_update(PySetObject *so, PyObject *const *args, Py_ssize_t nargs)
others = args;
others_length = nargs;
return_value = set_update_impl(so, others, others_length);
return_value = set_update_impl((PySetObject *)so, others, others_length);
return return_value;
}
@ -70,12 +70,12 @@ static PyObject *
set_copy_impl(PySetObject *so);
static PyObject *
set_copy(PySetObject *so, PyObject *Py_UNUSED(ignored))
set_copy(PyObject *so, PyObject *Py_UNUSED(ignored))
{
PyObject *return_value = NULL;
Py_BEGIN_CRITICAL_SECTION(so);
return_value = set_copy_impl(so);
return_value = set_copy_impl((PySetObject *)so);
Py_END_CRITICAL_SECTION();
return return_value;
@ -94,12 +94,12 @@ static PyObject *
frozenset_copy_impl(PySetObject *so);
static PyObject *
frozenset_copy(PySetObject *so, PyObject *Py_UNUSED(ignored))
frozenset_copy(PyObject *so, PyObject *Py_UNUSED(ignored))
{
PyObject *return_value = NULL;
Py_BEGIN_CRITICAL_SECTION(so);
return_value = frozenset_copy_impl(so);
return_value = frozenset_copy_impl((PySetObject *)so);
Py_END_CRITICAL_SECTION();
return return_value;
@ -118,12 +118,12 @@ static PyObject *
set_clear_impl(PySetObject *so);
static PyObject *
set_clear(PySetObject *so, PyObject *Py_UNUSED(ignored))
set_clear(PyObject *so, PyObject *Py_UNUSED(ignored))
{
PyObject *return_value = NULL;
Py_BEGIN_CRITICAL_SECTION(so);
return_value = set_clear_impl(so);
return_value = set_clear_impl((PySetObject *)so);
Py_END_CRITICAL_SECTION();
return return_value;
@ -143,7 +143,7 @@ set_union_impl(PySetObject *so, PyObject * const *others,
Py_ssize_t others_length);
static PyObject *
set_union(PySetObject *so, PyObject *const *args, Py_ssize_t nargs)
set_union(PyObject *so, PyObject *const *args, Py_ssize_t nargs)
{
PyObject *return_value = NULL;
PyObject * const *others;
@ -151,7 +151,7 @@ set_union(PySetObject *so, PyObject *const *args, Py_ssize_t nargs)
others = args;
others_length = nargs;
return_value = set_union_impl(so, others, others_length);
return_value = set_union_impl((PySetObject *)so, others, others_length);
return return_value;
}
@ -170,7 +170,7 @@ set_intersection_multi_impl(PySetObject *so, PyObject * const *others,
Py_ssize_t others_length);
static PyObject *
set_intersection_multi(PySetObject *so, PyObject *const *args, Py_ssize_t nargs)
set_intersection_multi(PyObject *so, PyObject *const *args, Py_ssize_t nargs)
{
PyObject *return_value = NULL;
PyObject * const *others;
@ -178,7 +178,7 @@ set_intersection_multi(PySetObject *so, PyObject *const *args, Py_ssize_t nargs)
others = args;
others_length = nargs;
return_value = set_intersection_multi_impl(so, others, others_length);
return_value = set_intersection_multi_impl((PySetObject *)so, others, others_length);
return return_value;
}
@ -197,7 +197,7 @@ set_intersection_update_multi_impl(PySetObject *so, PyObject * const *others,
Py_ssize_t others_length);
static PyObject *
set_intersection_update_multi(PySetObject *so, PyObject *const *args, Py_ssize_t nargs)
set_intersection_update_multi(PyObject *so, PyObject *const *args, Py_ssize_t nargs)
{
PyObject *return_value = NULL;
PyObject * const *others;
@ -205,7 +205,7 @@ set_intersection_update_multi(PySetObject *so, PyObject *const *args, Py_ssize_t
others = args;
others_length = nargs;
return_value = set_intersection_update_multi_impl(so, others, others_length);
return_value = set_intersection_update_multi_impl((PySetObject *)so, others, others_length);
return return_value;
}
@ -228,7 +228,7 @@ set_isdisjoint(PySetObject *so, PyObject *other)
PyObject *return_value = NULL;
Py_BEGIN_CRITICAL_SECTION2(so, other);
return_value = set_isdisjoint_impl(so, other);
return_value = set_isdisjoint_impl((PySetObject *)so, other);
Py_END_CRITICAL_SECTION2();
return return_value;
@ -248,7 +248,7 @@ set_difference_update_impl(PySetObject *so, PyObject * const *others,
Py_ssize_t others_length);
static PyObject *
set_difference_update(PySetObject *so, PyObject *const *args, Py_ssize_t nargs)
set_difference_update(PyObject *so, PyObject *const *args, Py_ssize_t nargs)
{
PyObject *return_value = NULL;
PyObject * const *others;
@ -256,7 +256,7 @@ set_difference_update(PySetObject *so, PyObject *const *args, Py_ssize_t nargs)
others = args;
others_length = nargs;
return_value = set_difference_update_impl(so, others, others_length);
return_value = set_difference_update_impl((PySetObject *)so, others, others_length);
return return_value;
}
@ -275,7 +275,7 @@ set_difference_multi_impl(PySetObject *so, PyObject * const *others,
Py_ssize_t others_length);
static PyObject *
set_difference_multi(PySetObject *so, PyObject *const *args, Py_ssize_t nargs)
set_difference_multi(PyObject *so, PyObject *const *args, Py_ssize_t nargs)
{
PyObject *return_value = NULL;
PyObject * const *others;
@ -283,7 +283,7 @@ set_difference_multi(PySetObject *so, PyObject *const *args, Py_ssize_t nargs)
others = args;
others_length = nargs;
return_value = set_difference_multi_impl(so, others, others_length);
return_value = set_difference_multi_impl((PySetObject *)so, others, others_length);
return return_value;
}
@ -315,7 +315,7 @@ set_symmetric_difference(PySetObject *so, PyObject *other)
PyObject *return_value = NULL;
Py_BEGIN_CRITICAL_SECTION2(so, other);
return_value = set_symmetric_difference_impl(so, other);
return_value = set_symmetric_difference_impl((PySetObject *)so, other);
Py_END_CRITICAL_SECTION2();
return return_value;
@ -339,7 +339,7 @@ set_issubset(PySetObject *so, PyObject *other)
PyObject *return_value = NULL;
Py_BEGIN_CRITICAL_SECTION2(so, other);
return_value = set_issubset_impl(so, other);
return_value = set_issubset_impl((PySetObject *)so, other);
Py_END_CRITICAL_SECTION2();
return return_value;
@ -363,7 +363,7 @@ set_issuperset(PySetObject *so, PyObject *other)
PyObject *return_value = NULL;
Py_BEGIN_CRITICAL_SECTION2(so, other);
return_value = set_issuperset_impl(so, other);
return_value = set_issuperset_impl((PySetObject *)so, other);
Py_END_CRITICAL_SECTION2();
return return_value;
@ -389,7 +389,7 @@ set_add(PySetObject *so, PyObject *key)
PyObject *return_value = NULL;
Py_BEGIN_CRITICAL_SECTION(so);
return_value = set_add_impl(so, key);
return_value = set_add_impl((PySetObject *)so, key);
Py_END_CRITICAL_SECTION();
return return_value;
@ -413,7 +413,7 @@ set___contains__(PySetObject *so, PyObject *key)
PyObject *return_value = NULL;
Py_BEGIN_CRITICAL_SECTION(so);
return_value = set___contains___impl(so, key);
return_value = set___contains___impl((PySetObject *)so, key);
Py_END_CRITICAL_SECTION();
return return_value;
@ -439,7 +439,7 @@ set_remove(PySetObject *so, PyObject *key)
PyObject *return_value = NULL;
Py_BEGIN_CRITICAL_SECTION(so);
return_value = set_remove_impl(so, key);
return_value = set_remove_impl((PySetObject *)so, key);
Py_END_CRITICAL_SECTION();
return return_value;
@ -466,7 +466,7 @@ set_discard(PySetObject *so, PyObject *key)
PyObject *return_value = NULL;
Py_BEGIN_CRITICAL_SECTION(so);
return_value = set_discard_impl(so, key);
return_value = set_discard_impl((PySetObject *)so, key);
Py_END_CRITICAL_SECTION();
return return_value;
@ -485,12 +485,12 @@ static PyObject *
set___reduce___impl(PySetObject *so);
static PyObject *
set___reduce__(PySetObject *so, PyObject *Py_UNUSED(ignored))
set___reduce__(PyObject *so, PyObject *Py_UNUSED(ignored))
{
PyObject *return_value = NULL;
Py_BEGIN_CRITICAL_SECTION(so);
return_value = set___reduce___impl(so);
return_value = set___reduce___impl((PySetObject *)so);
Py_END_CRITICAL_SECTION();
return return_value;
@ -509,14 +509,14 @@ static PyObject *
set___sizeof___impl(PySetObject *so);
static PyObject *
set___sizeof__(PySetObject *so, PyObject *Py_UNUSED(ignored))
set___sizeof__(PyObject *so, PyObject *Py_UNUSED(ignored))
{
PyObject *return_value = NULL;
Py_BEGIN_CRITICAL_SECTION(so);
return_value = set___sizeof___impl(so);
return_value = set___sizeof___impl((PySetObject *)so);
Py_END_CRITICAL_SECTION();
return return_value;
}
/*[clinic end generated code: output=4b65e7709927f31f input=a9049054013a1b77]*/
/*[clinic end generated code: output=83b7742a762ce465 input=a9049054013a1b77]*/

View file

@ -20,7 +20,7 @@ tuple_index_impl(PyTupleObject *self, PyObject *value, Py_ssize_t start,
Py_ssize_t stop);
static PyObject *
tuple_index(PyTupleObject *self, PyObject *const *args, Py_ssize_t nargs)
tuple_index(PyObject *self, PyObject *const *args, Py_ssize_t nargs)
{
PyObject *return_value = NULL;
PyObject *value;
@ -44,7 +44,7 @@ tuple_index(PyTupleObject *self, PyObject *const *args, Py_ssize_t nargs)
goto exit;
}
skip_optional:
return_value = tuple_index_impl(self, value, start, stop);
return_value = tuple_index_impl((PyTupleObject *)self, value, start, stop);
exit:
return return_value;
@ -110,8 +110,8 @@ static PyObject *
tuple___getnewargs___impl(PyTupleObject *self);
static PyObject *
tuple___getnewargs__(PyTupleObject *self, PyObject *Py_UNUSED(ignored))
tuple___getnewargs__(PyObject *self, PyObject *Py_UNUSED(ignored))
{
return tuple___getnewargs___impl(self);
return tuple___getnewargs___impl((PyTupleObject *)self);
}
/*[clinic end generated code: output=a6a9abba5d121f4c input=a9049054013a1b77]*/
/*[clinic end generated code: output=779cb4a13db67397 input=a9049054013a1b77]*/

View file

@ -22,7 +22,7 @@ type___instancecheck__(PyTypeObject *self, PyObject *instance)
PyObject *return_value = NULL;
int _return_value;
_return_value = type___instancecheck___impl(self, instance);
_return_value = type___instancecheck___impl((PyTypeObject *)self, instance);
if ((_return_value == -1) && PyErr_Occurred()) {
goto exit;
}
@ -50,7 +50,7 @@ type___subclasscheck__(PyTypeObject *self, PyObject *subclass)
PyObject *return_value = NULL;
int _return_value;
_return_value = type___subclasscheck___impl(self, subclass);
_return_value = type___subclasscheck___impl((PyTypeObject *)self, subclass);
if ((_return_value == -1) && PyErr_Occurred()) {
goto exit;
}
@ -73,9 +73,9 @@ static PyObject *
type_mro_impl(PyTypeObject *self);
static PyObject *
type_mro(PyTypeObject *self, PyObject *Py_UNUSED(ignored))
type_mro(PyObject *self, PyObject *Py_UNUSED(ignored))
{
return type_mro_impl(self);
return type_mro_impl((PyTypeObject *)self);
}
PyDoc_STRVAR(type___subclasses____doc__,
@ -91,9 +91,9 @@ static PyObject *
type___subclasses___impl(PyTypeObject *self);
static PyObject *
type___subclasses__(PyTypeObject *self, PyObject *Py_UNUSED(ignored))
type___subclasses__(PyObject *self, PyObject *Py_UNUSED(ignored))
{
return type___subclasses___impl(self);
return type___subclasses___impl((PyTypeObject *)self);
}
PyDoc_STRVAR(type___dir____doc__,
@ -109,9 +109,9 @@ static PyObject *
type___dir___impl(PyTypeObject *self);
static PyObject *
type___dir__(PyTypeObject *self, PyObject *Py_UNUSED(ignored))
type___dir__(PyObject *self, PyObject *Py_UNUSED(ignored))
{
return type___dir___impl(self);
return type___dir___impl((PyTypeObject *)self);
}
PyDoc_STRVAR(type___sizeof____doc__,
@ -127,9 +127,9 @@ static PyObject *
type___sizeof___impl(PyTypeObject *self);
static PyObject *
type___sizeof__(PyTypeObject *self, PyObject *Py_UNUSED(ignored))
type___sizeof__(PyObject *self, PyObject *Py_UNUSED(ignored))
{
return type___sizeof___impl(self);
return type___sizeof___impl((PyTypeObject *)self);
}
PyDoc_STRVAR(object___getstate____doc__,
@ -262,4 +262,4 @@ object___dir__(PyObject *self, PyObject *Py_UNUSED(ignored))
{
return object___dir___impl(self);
}
/*[clinic end generated code: output=b56c87f9cace1921 input=a9049054013a1b77]*/
/*[clinic end generated code: output=f7db85fd11818c63 input=a9049054013a1b77]*/

View file

@ -143,7 +143,7 @@ typevar_typing_prepare_subst_impl(typevarobject *self, PyObject *alias,
PyObject *args);
static PyObject *
typevar_typing_prepare_subst(typevarobject *self, PyObject *const *args, Py_ssize_t nargs)
typevar_typing_prepare_subst(PyObject *self, PyObject *const *args, Py_ssize_t nargs)
{
PyObject *return_value = NULL;
PyObject *alias;
@ -154,7 +154,7 @@ typevar_typing_prepare_subst(typevarobject *self, PyObject *const *args, Py_ssiz
}
alias = args[0];
__clinic_args = args[1];
return_value = typevar_typing_prepare_subst_impl(self, alias, __clinic_args);
return_value = typevar_typing_prepare_subst_impl((typevarobject *)self, alias, __clinic_args);
exit:
return return_value;
@ -172,9 +172,9 @@ static PyObject *
typevar_reduce_impl(typevarobject *self);
static PyObject *
typevar_reduce(typevarobject *self, PyObject *Py_UNUSED(ignored))
typevar_reduce(PyObject *self, PyObject *Py_UNUSED(ignored))
{
return typevar_reduce_impl(self);
return typevar_reduce_impl((typevarobject *)self);
}
PyDoc_STRVAR(typevar_has_default__doc__,
@ -189,9 +189,9 @@ static PyObject *
typevar_has_default_impl(typevarobject *self);
static PyObject *
typevar_has_default(typevarobject *self, PyObject *Py_UNUSED(ignored))
typevar_has_default(PyObject *self, PyObject *Py_UNUSED(ignored))
{
return typevar_has_default_impl(self);
return typevar_has_default_impl((typevarobject *)self);
}
PyDoc_STRVAR(paramspecargs_new__doc__,
@ -431,7 +431,7 @@ paramspec_typing_prepare_subst_impl(paramspecobject *self, PyObject *alias,
PyObject *args);
static PyObject *
paramspec_typing_prepare_subst(paramspecobject *self, PyObject *const *args, Py_ssize_t nargs)
paramspec_typing_prepare_subst(PyObject *self, PyObject *const *args, Py_ssize_t nargs)
{
PyObject *return_value = NULL;
PyObject *alias;
@ -442,7 +442,7 @@ paramspec_typing_prepare_subst(paramspecobject *self, PyObject *const *args, Py_
}
alias = args[0];
__clinic_args = args[1];
return_value = paramspec_typing_prepare_subst_impl(self, alias, __clinic_args);
return_value = paramspec_typing_prepare_subst_impl((paramspecobject *)self, alias, __clinic_args);
exit:
return return_value;
@ -460,9 +460,9 @@ static PyObject *
paramspec_reduce_impl(paramspecobject *self);
static PyObject *
paramspec_reduce(paramspecobject *self, PyObject *Py_UNUSED(ignored))
paramspec_reduce(PyObject *self, PyObject *Py_UNUSED(ignored))
{
return paramspec_reduce_impl(self);
return paramspec_reduce_impl((paramspecobject *)self);
}
PyDoc_STRVAR(paramspec_has_default__doc__,
@ -477,9 +477,9 @@ static PyObject *
paramspec_has_default_impl(paramspecobject *self);
static PyObject *
paramspec_has_default(paramspecobject *self, PyObject *Py_UNUSED(ignored))
paramspec_has_default(PyObject *self, PyObject *Py_UNUSED(ignored))
{
return paramspec_has_default_impl(self);
return paramspec_has_default_impl((paramspecobject *)self);
}
PyDoc_STRVAR(typevartuple__doc__,
@ -570,7 +570,7 @@ typevartuple_typing_prepare_subst_impl(typevartupleobject *self,
PyObject *alias, PyObject *args);
static PyObject *
typevartuple_typing_prepare_subst(typevartupleobject *self, PyObject *const *args, Py_ssize_t nargs)
typevartuple_typing_prepare_subst(PyObject *self, PyObject *const *args, Py_ssize_t nargs)
{
PyObject *return_value = NULL;
PyObject *alias;
@ -581,7 +581,7 @@ typevartuple_typing_prepare_subst(typevartupleobject *self, PyObject *const *arg
}
alias = args[0];
__clinic_args = args[1];
return_value = typevartuple_typing_prepare_subst_impl(self, alias, __clinic_args);
return_value = typevartuple_typing_prepare_subst_impl((typevartupleobject *)self, alias, __clinic_args);
exit:
return return_value;
@ -599,9 +599,9 @@ static PyObject *
typevartuple_reduce_impl(typevartupleobject *self);
static PyObject *
typevartuple_reduce(typevartupleobject *self, PyObject *Py_UNUSED(ignored))
typevartuple_reduce(PyObject *self, PyObject *Py_UNUSED(ignored))
{
return typevartuple_reduce_impl(self);
return typevartuple_reduce_impl((typevartupleobject *)self);
}
PyDoc_STRVAR(typevartuple_has_default__doc__,
@ -616,9 +616,9 @@ static PyObject *
typevartuple_has_default_impl(typevartupleobject *self);
static PyObject *
typevartuple_has_default(typevartupleobject *self, PyObject *Py_UNUSED(ignored))
typevartuple_has_default(PyObject *self, PyObject *Py_UNUSED(ignored))
{
return typevartuple_has_default_impl(self);
return typevartuple_has_default_impl((typevartupleobject *)self);
}
PyDoc_STRVAR(typealias_reduce__doc__,
@ -633,9 +633,9 @@ static PyObject *
typealias_reduce_impl(typealiasobject *self);
static PyObject *
typealias_reduce(typealiasobject *self, PyObject *Py_UNUSED(ignored))
typealias_reduce(PyObject *self, PyObject *Py_UNUSED(ignored))
{
return typealias_reduce_impl(self);
return typealias_reduce_impl((typealiasobject *)self);
}
PyDoc_STRVAR(typealias_new__doc__,
@ -706,4 +706,4 @@ skip_optional_kwonly:
exit:
return return_value;
}
/*[clinic end generated code: output=26351c3549f5ad83 input=a9049054013a1b77]*/
/*[clinic end generated code: output=f499d959a942c599 input=a9049054013a1b77]*/

View file

@ -22,9 +22,9 @@ static PyObject *
EncodingMap_size_impl(struct encoding_map *self);
static PyObject *
EncodingMap_size(struct encoding_map *self, PyObject *Py_UNUSED(ignored))
EncodingMap_size(PyObject *self, PyObject *Py_UNUSED(ignored))
{
return EncodingMap_size_impl(self);
return EncodingMap_size_impl((struct encoding_map *)self);
}
PyDoc_STRVAR(unicode_title__doc__,
@ -1895,4 +1895,4 @@ skip_optional_pos:
exit:
return return_value;
}
/*[clinic end generated code: output=30efbf79c5a07dd2 input=a9049054013a1b77]*/
/*[clinic end generated code: output=4d1cecd6d08498a4 input=a9049054013a1b77]*/

View file

@ -2212,24 +2212,24 @@ code_branchesiterator(PyObject *self, PyObject *Py_UNUSED(args))
code.replace
*
co_argcount: int(c_default="self->co_argcount") = unchanged
co_posonlyargcount: int(c_default="self->co_posonlyargcount") = unchanged
co_kwonlyargcount: int(c_default="self->co_kwonlyargcount") = unchanged
co_nlocals: int(c_default="self->co_nlocals") = unchanged
co_stacksize: int(c_default="self->co_stacksize") = unchanged
co_flags: int(c_default="self->co_flags") = unchanged
co_firstlineno: int(c_default="self->co_firstlineno") = unchanged
co_argcount: int(c_default="((PyCodeObject *)self)->co_argcount") = unchanged
co_posonlyargcount: int(c_default="((PyCodeObject *)self)->co_posonlyargcount") = unchanged
co_kwonlyargcount: int(c_default="((PyCodeObject *)self)->co_kwonlyargcount") = unchanged
co_nlocals: int(c_default="((PyCodeObject *)self)->co_nlocals") = unchanged
co_stacksize: int(c_default="((PyCodeObject *)self)->co_stacksize") = unchanged
co_flags: int(c_default="((PyCodeObject *)self)->co_flags") = unchanged
co_firstlineno: int(c_default="((PyCodeObject *)self)->co_firstlineno") = unchanged
co_code: object(subclass_of="&PyBytes_Type", c_default="NULL") = unchanged
co_consts: object(subclass_of="&PyTuple_Type", c_default="self->co_consts") = unchanged
co_names: object(subclass_of="&PyTuple_Type", c_default="self->co_names") = unchanged
co_consts: object(subclass_of="&PyTuple_Type", c_default="((PyCodeObject *)self)->co_consts") = unchanged
co_names: object(subclass_of="&PyTuple_Type", c_default="((PyCodeObject *)self)->co_names") = unchanged
co_varnames: object(subclass_of="&PyTuple_Type", c_default="NULL") = unchanged
co_freevars: object(subclass_of="&PyTuple_Type", c_default="NULL") = unchanged
co_cellvars: object(subclass_of="&PyTuple_Type", c_default="NULL") = unchanged
co_filename: unicode(c_default="self->co_filename") = unchanged
co_name: unicode(c_default="self->co_name") = unchanged
co_qualname: unicode(c_default="self->co_qualname") = unchanged
co_linetable: object(subclass_of="&PyBytes_Type", c_default="self->co_linetable") = unchanged
co_exceptiontable: object(subclass_of="&PyBytes_Type", c_default="self->co_exceptiontable") = unchanged
co_filename: unicode(c_default="((PyCodeObject *)self)->co_filename") = unchanged
co_name: unicode(c_default="((PyCodeObject *)self)->co_name") = unchanged
co_qualname: unicode(c_default="((PyCodeObject *)self)->co_qualname") = unchanged
co_linetable: object(subclass_of="&PyBytes_Type", c_default="((PyCodeObject *)self)->co_linetable") = unchanged
co_exceptiontable: object(subclass_of="&PyBytes_Type", c_default="((PyCodeObject *)self)->co_exceptiontable") = unchanged
Return a copy of the code object with new values for the specified fields.
[clinic start generated code]*/
@ -2244,7 +2244,7 @@ code_replace_impl(PyCodeObject *self, int co_argcount,
PyObject *co_filename, PyObject *co_name,
PyObject *co_qualname, PyObject *co_linetable,
PyObject *co_exceptiontable)
/*[clinic end generated code: output=e75c48a15def18b9 input=18e280e07846c122]*/
/*[clinic end generated code: output=e75c48a15def18b9 input=a455a89c57ac9d42]*/
{
#define CHECK_INT_ARG(ARG) \
if (ARG < 0) { \

View file

@ -1298,7 +1298,7 @@ set_union_impl(PySetObject *so, PyObject * const *others,
PyObject *other;
Py_ssize_t i;
result = (PySetObject *)set_copy(so, NULL);
result = (PySetObject *)set_copy((PyObject *)so, NULL);
if (result == NULL)
return NULL;
@ -1321,13 +1321,12 @@ set_or(PyObject *self, PyObject *other)
if (!PyAnySet_Check(self) || !PyAnySet_Check(other))
Py_RETURN_NOTIMPLEMENTED;
PySetObject *so = _PySet_CAST(self);
result = (PySetObject *)set_copy(so, NULL);
result = (PySetObject *)set_copy(self, NULL);
if (result == NULL) {
return NULL;
}
if (Py_Is((PyObject *)so, other)) {
if (Py_Is(self, other)) {
return (PyObject *)result;
}
if (set_update_local(result, other)) {
@ -1449,7 +1448,7 @@ set_intersection_multi_impl(PySetObject *so, PyObject * const *others,
Py_ssize_t i;
if (others_length == 0) {
return set_copy(so, NULL);
return set_copy((PyObject *)so, NULL);
}
PyObject *result = Py_NewRef(so);
@ -1806,7 +1805,7 @@ set_difference_multi_impl(PySetObject *so, PyObject * const *others,
PyObject *result, *other;
if (others_length == 0) {
return set_copy(so, NULL);
return set_copy((PyObject *)so, NULL);
}
other = others[0];
@ -1929,7 +1928,7 @@ set_symmetric_difference_update(PySetObject *so, PyObject *other)
/*[clinic end generated code: output=fbb049c0806028de input=a50acf0365e1f0a5]*/
{
if (Py_Is((PyObject *)so, other)) {
return set_clear(so, NULL);
return set_clear((PyObject *)so, NULL);
}
int rv;
@ -2646,7 +2645,7 @@ PySet_Clear(PyObject *set)
PyErr_BadInternalCall();
return -1;
}
(void)set_clear((PySetObject *)set, NULL);
(void)set_clear(set, NULL);
return 0;
}
@ -2742,7 +2741,7 @@ PySet_Pop(PyObject *set)
PyErr_BadInternalCall();
return NULL;
}
return set_pop((PySetObject *)set, NULL);
return set_pop(set, NULL);
}
int