mirror of
https://github.com/python/cpython.git
synced 2025-08-04 08:59:19 +00:00
Change PyBuffer to Py_buffer to be consistent with other non-object structures like Py_complex. Add some more functionality to the memoryview object.
This commit is contained in:
parent
3f993c3b52
commit
8ae62b6094
16 changed files with 145 additions and 85 deletions
|
@ -1784,7 +1784,7 @@ static const void *emptybuf = "";
|
|||
|
||||
|
||||
static int
|
||||
array_buffer_getbuf(arrayobject *self, PyBuffer *view, int flags)
|
||||
array_buffer_getbuf(arrayobject *self, Py_buffer *view, int flags)
|
||||
{
|
||||
if ((flags & PyBUF_CHARACTER)) {
|
||||
PyErr_SetString(PyExc_TypeError,
|
||||
|
@ -1825,7 +1825,7 @@ array_buffer_getbuf(arrayobject *self, PyBuffer *view, int flags)
|
|||
}
|
||||
|
||||
static void
|
||||
array_buffer_relbuf(arrayobject *self, PyBuffer *view)
|
||||
array_buffer_relbuf(arrayobject *self, Py_buffer *view)
|
||||
{
|
||||
self->ob_exports--;
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue