mirror of
https://github.com/python/cpython.git
synced 2025-08-04 00:48:58 +00:00
gh-108444: Argument Clinic uses PyLong_AsInt() (#108458)
Argument Clinic now uses the new public PyLong_AsInt(), rather than the old name _PyLong_AsInt().
This commit is contained in:
parent
be800f4be7
commit
4e5a7284ee
73 changed files with 467 additions and 466 deletions
12
Python/clinic/bltinmodule.c.h
generated
12
Python/clinic/bltinmodule.c.h
generated
|
@ -99,7 +99,7 @@ builtin___import__(PyObject *module, PyObject *const *args, Py_ssize_t nargs, Py
|
|||
goto skip_optional_pos;
|
||||
}
|
||||
}
|
||||
level = _PyLong_AsInt(args[4]);
|
||||
level = PyLong_AsInt(args[4]);
|
||||
if (level == -1 && PyErr_Occurred()) {
|
||||
goto exit;
|
||||
}
|
||||
|
@ -242,7 +242,7 @@ builtin_chr(PyObject *module, PyObject *arg)
|
|||
PyObject *return_value = NULL;
|
||||
int i;
|
||||
|
||||
i = _PyLong_AsInt(arg);
|
||||
i = PyLong_AsInt(arg);
|
||||
if (i == -1 && PyErr_Occurred()) {
|
||||
goto exit;
|
||||
}
|
||||
|
@ -342,7 +342,7 @@ builtin_compile(PyObject *module, PyObject *const *args, Py_ssize_t nargs, PyObj
|
|||
goto skip_optional_pos;
|
||||
}
|
||||
if (args[3]) {
|
||||
flags = _PyLong_AsInt(args[3]);
|
||||
flags = PyLong_AsInt(args[3]);
|
||||
if (flags == -1 && PyErr_Occurred()) {
|
||||
goto exit;
|
||||
}
|
||||
|
@ -360,7 +360,7 @@ builtin_compile(PyObject *module, PyObject *const *args, Py_ssize_t nargs, PyObj
|
|||
}
|
||||
}
|
||||
if (args[5]) {
|
||||
optimize = _PyLong_AsInt(args[5]);
|
||||
optimize = PyLong_AsInt(args[5]);
|
||||
if (optimize == -1 && PyErr_Occurred()) {
|
||||
goto exit;
|
||||
}
|
||||
|
@ -372,7 +372,7 @@ skip_optional_pos:
|
|||
if (!noptargs) {
|
||||
goto skip_optional_kwonly;
|
||||
}
|
||||
feature_version = _PyLong_AsInt(args[6]);
|
||||
feature_version = PyLong_AsInt(args[6]);
|
||||
if (feature_version == -1 && PyErr_Occurred()) {
|
||||
goto exit;
|
||||
}
|
||||
|
@ -1212,4 +1212,4 @@ builtin_issubclass(PyObject *module, PyObject *const *args, Py_ssize_t nargs)
|
|||
exit:
|
||||
return return_value;
|
||||
}
|
||||
/*[clinic end generated code: output=daeee81b018824f4 input=a9049054013a1b77]*/
|
||||
/*[clinic end generated code: output=bb2da8ccae4190e9 input=a9049054013a1b77]*/
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue