summaryrefslogtreecommitdiffstats
path: root/Include/cpython/abstract.h
diff options
context:
space:
mode:
authorDavid Hewitt <1939362+davidhewitt@users.noreply.github.com>2021-12-22 13:07:46 (GMT)
committerGitHub <noreply@github.com>2021-12-22 13:07:46 (GMT)
commit31ff96712e8f89ac1056c2da880b44650002219f (patch)
treef6cbc0c62bb78c3251a2ff7364fba22b6b36007a /Include/cpython/abstract.h
parentfc54e722a2e66971f1a8e16cff24c844bf9c5ac4 (diff)
downloadcpython-31ff96712e8f89ac1056c2da880b44650002219f.zip
cpython-31ff96712e8f89ac1056c2da880b44650002219f.tar.gz
cpython-31ff96712e8f89ac1056c2da880b44650002219f.tar.bz2
bpo-46140: take more Py_buffer arguments as const * (GH-30217)
Diffstat (limited to 'Include/cpython/abstract.h')
-rw-r--r--Include/cpython/abstract.h6
1 files changed, 3 insertions, 3 deletions
diff --git a/Include/cpython/abstract.h b/Include/cpython/abstract.h
index 55a742c..2876a7b 100644
--- a/Include/cpython/abstract.h
+++ b/Include/cpython/abstract.h
@@ -183,17 +183,17 @@ PyAPI_FUNC(int) PyObject_GetBuffer(PyObject *obj, Py_buffer *view,
/* Get the memory area pointed to by the indices for the buffer given.
Note that view->ndim is the assumed size of indices. */
-PyAPI_FUNC(void *) PyBuffer_GetPointer(Py_buffer *view, Py_ssize_t *indices);
+PyAPI_FUNC(void *) PyBuffer_GetPointer(const Py_buffer *view, const Py_ssize_t *indices);
/* Return the implied itemsize of the data-format area from a
struct-style description. */
PyAPI_FUNC(Py_ssize_t) PyBuffer_SizeFromFormat(const char *format);
/* Implementation in memoryobject.c */
-PyAPI_FUNC(int) PyBuffer_ToContiguous(void *buf, Py_buffer *view,
+PyAPI_FUNC(int) PyBuffer_ToContiguous(void *buf, const Py_buffer *view,
Py_ssize_t len, char order);
-PyAPI_FUNC(int) PyBuffer_FromContiguous(Py_buffer *view, void *buf,
+PyAPI_FUNC(int) PyBuffer_FromContiguous(const Py_buffer *view, const void *buf,
Py_ssize_t len, char order);
/* Copy len bytes of data from the contiguous chunk of memory