bpo-32240: Add the const qualifier to declarations of PyObject* array arguments. (#4746)

This commit is contained in:
Serhiy Storchaka 2017-12-15 13:11:11 +02:00 committed by GitHub
parent 3325a6780c
commit a5552f023e
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
88 changed files with 669 additions and 662 deletions

View file

@ -1733,7 +1733,7 @@ Struct_iter_unpack(PyStructObject *self, PyObject *buffer)
*
*/
static int
s_pack_internal(PyStructObject *soself, PyObject **args, int offset, char* buf)
s_pack_internal(PyStructObject *soself, PyObject *const *args, int offset, char* buf)
{
formatcode *code;
/* XXX(nnorwitz): why does i need to be a local? can we use
@ -1820,7 +1820,7 @@ to the format string S.format. See help(struct) for more on format\n\
strings.");
static PyObject *
s_pack(PyObject *self, PyObject **args, Py_ssize_t nargs)
s_pack(PyObject *self, PyObject *const *args, Py_ssize_t nargs)
{
PyStructObject *soself;
PyObject *result;
@ -1859,7 +1859,7 @@ offset. Note that the offset is a required argument. See\n\
help(struct) for more on format strings.");
static PyObject *
s_pack_into(PyObject *self, PyObject **args, Py_ssize_t nargs)
s_pack_into(PyObject *self, PyObject *const *args, Py_ssize_t nargs)
{
PyStructObject *soself;
Py_buffer buffer;
@ -2123,7 +2123,7 @@ Return a bytes object containing the values v1, v2, ... packed according\n\
to the format string. See help(struct) for more on format strings.");
static PyObject *
pack(PyObject *self, PyObject **args, Py_ssize_t nargs)
pack(PyObject *self, PyObject *const *args, Py_ssize_t nargs)
{
PyObject *s_object = NULL;
PyObject *format, *result;
@ -2151,7 +2151,7 @@ that the offset is a required argument. See help(struct) for more\n\
on format strings.");
static PyObject *
pack_into(PyObject *self, PyObject **args, Py_ssize_t nargs)
pack_into(PyObject *self, PyObject *const *args, Py_ssize_t nargs)
{
PyObject *s_object = NULL;
PyObject *format, *result;