Author martin.panter
Recipients cblp, dabeaz, josh.r, martin.panter, pitrou, skrah
Date 2015-08-06.00:44:04
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <>
In my experience, I tend to only use memoryview() for “bytes-like” buffers (but see Issue 23756 about clarifying what this means). Example from /Lib/

def readinto(self, b):
    with memoryview(b) as view, view.cast("B") as byte_view:
        data =
        byte_view[:len(data)] = data
    return len(data)

Fixing cast("B") or adding a memoryview(raw=True) mode could probably help when all you want is a byte buffer.
Date User Action Args
2015-08-06 00:44:05martin.pantersetrecipients: + martin.panter, pitrou, skrah, dabeaz, cblp, josh.r
2015-08-06 00:44:05martin.pantersetmessageid: <>
2015-08-06 00:44:05martin.panterlinkissue15944 messages
2015-08-06 00:44:04martin.pantercreate