New submission from Joannah Nanjekye <nanjekyejoan...@gmail.com>:
We have a memory-view object represented with the following structure: typedef struct { PyObject_VAR_HEAD _PyManagedBufferObject *mbuf; /* managed buffer */ Py_hash_t hash; /* hash value for read-only views */ int flags; /* state flags */ Py_ssize_t exports; /* number of buffer re-exports */ Py_buffer view; /* private copy of the exporter's view */ PyObject *weakreflist; Py_ssize_t ob_array[1]; /* shape, strides, suboffsets */ } PyMemoryViewObject; It would be good to have the implementation for PyObject_GetMemoryView which returns a memory-view object as was originally intended in PEP 3118 i.e : PyObject *PyObject_GetMemoryView(PyObject *obj) ---------- components: C API messages: 363265 nosy: nanjekyejoannah priority: normal severity: normal status: open title: Implement PyObject_GetMemoryView type: enhancement versions: Python 3.9 _______________________________________ Python tracker <rep...@bugs.python.org> <https://bugs.python.org/issue39836> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com