mirror of
https://github.com/python/cpython.git
synced 2026-01-06 15:32:22 +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
|
|
@ -1160,7 +1160,7 @@ string_subscript(PyStringObject* self, PyObject* item)
|
|||
}
|
||||
|
||||
static int
|
||||
string_buffer_getbuffer(PyStringObject *self, PyBuffer *view, int flags)
|
||||
string_buffer_getbuffer(PyStringObject *self, Py_buffer *view, int flags)
|
||||
{
|
||||
return PyBuffer_FillInfo(view, (void *)self->ob_sval, Py_Size(self), 0, flags);
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue