Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
- Notifications
You must be signed in to change notification settings - Fork 35.2k
gh-104922: Make PY_SSIZE_T_CLEAN not mandatory#104923
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Uh oh!
There was an error while loading. Please reload this page.
Changes from all commits
5b26c2180eefbf30a20f12df6cc3bade6502aa6af5b4f0c3af11eb51File filter
Filter by extension
Conversations
Uh oh!
There was an error while loading. Please reload this page.
Jump to
Uh oh!
There was an error while loading. Please reload this page.
Diff view
Diff view
There are no files selected for viewing
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Uh oh!
There was an error while loading. Please reload this page.
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -2,19 +2,19 @@ | ||
| # error "this header file must not be included directly" | ||
| #endif | ||
| /* If PY_SSIZE_T_CLEAN is defined, each functions treats #-specifier | ||
| to mean Py_ssize_t */ | ||
| #ifdef PY_SSIZE_T_CLEAN | ||
| #define _Py_VaBuildStack _Py_VaBuildStack_SizeT | ||
| #else | ||
| PyAPI_FUNC(PyObject *) _Py_VaBuildValue_SizeT(const char *, va_list); | ||
| PyAPI_FUNC(PyObject **) _Py_VaBuildStack( | ||
| PyObject **small_stack, | ||
| Py_ssize_t small_stack_len, | ||
| const char *format, | ||
| va_list va, | ||
| Py_ssize_t *p_nargs); | ||
| PyAPI_FUNC(PyObject **) _Py_VaBuildStack_SizeT( | ||
| PyObject **small_stack, | ||
| Py_ssize_t small_stack_len, | ||
| const char *format, | ||
| va_list va, | ||
| Py_ssize_t *p_nargs); | ||
| #endif | ||
| ||
| PyAPI_FUNC(int) _PyArg_UnpackStack( | ||
| PyObject *const *args, | ||
| @@ -43,13 +43,6 @@ PyAPI_FUNC(int) _PyArg_CheckPositional(const char *, Py_ssize_t, | ||
| ((!_Py_ANY_VARARGS(max) && (min) <= (nargs) && (nargs) <= (max)) \ | ||
| || _PyArg_CheckPositional((funcname), (nargs), (min), (max))) | ||
| PyAPI_FUNC(PyObject **) _Py_VaBuildStack( | ||
| PyObject **small_stack, | ||
| Py_ssize_t small_stack_len, | ||
| const char *format, | ||
| va_list va, | ||
| Py_ssize_t *p_nargs); | ||
| typedef struct _PyArg_Parser { | ||
| int initialized; | ||
| const char *format; | ||
| @@ -63,13 +56,6 @@ typedef struct _PyArg_Parser { | ||
| struct _PyArg_Parser *next; | ||
| } _PyArg_Parser; | ||
| #ifdef PY_SSIZE_T_CLEAN | ||
| #define _PyArg_ParseTupleAndKeywordsFast _PyArg_ParseTupleAndKeywordsFast_SizeT | ||
| #define _PyArg_ParseStack _PyArg_ParseStack_SizeT | ||
| #define _PyArg_ParseStackAndKeywords _PyArg_ParseStackAndKeywords_SizeT | ||
| #define _PyArg_VaParseTupleAndKeywordsFast _PyArg_VaParseTupleAndKeywordsFast_SizeT | ||
| #endif | ||
| PyAPI_FUNC(int) _PyArg_ParseTupleAndKeywordsFast(PyObject *, PyObject *, | ||
| struct _PyArg_Parser *, ...); | ||
| PyAPI_FUNC(int) _PyArg_ParseStack( | ||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,2 @@ | ||
| ``PY_SSIZE_T_CLEAN`` is no longer required to use '#' specifier in APIs like | ||
| :c:func:`PyArg_ParseTuple` and :c:func:`Py_BuildValue`. |
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
These are not a part of stable ABI.
_PyObject_CallMethodId_SizeTis removed and_PyObject_CallMethodIdis ssize_t version.