This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author skrah
Recipients pitrou, rhansen, seberg, skrah
Date 2015-01-31.13:03:16
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1422709396.8.0.304975685749.issue23352@psf.upfronthosting.co.za>
In-reply-to
Content
Cython doesn't follow the spec though (use Python 3):

from _testbuffer import *

cpdef foo():
    cdef unsigned char[:] v = bytearray(b"testing")
    nd = ndarray(v, getbuf=PyBUF_ND)
    print(nd.suboffsets)
    nd = ndarray(v, getbuf=PyBUF_FULL)
    print(nd.suboffsets)


Cython hands out suboffsets even for a PyBUF_ND request, which is
definitely wrong.  For a PyBUF_FULL request they should only be
provided *if needed*.
History
Date User Action Args
2015-01-31 13:03:16skrahsetrecipients: + skrah, pitrou, rhansen, seberg
2015-01-31 13:03:16skrahsetmessageid: <1422709396.8.0.304975685749.issue23352@psf.upfronthosting.co.za>
2015-01-31 13:03:16skrahlinkissue23352 messages
2015-01-31 13:03:16skrahcreate