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 dabeaz, pitrou, skrah
Date 2014-10-16.21:46:19
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1413495979.68.0.153517927097.issue15944@psf.upfronthosting.co.za>
In-reply-to
Content
We could add a flag memoryview(x, raw=True) to the constructor.  This view 
would behave exactly like the regular one except that it ignores buf.format 
entirely.

So you could do assignments like:

   m[10] = b'\x00\x00\x00\x01'


This would be more flexible in general since memoryview currently only supports
native struct formats (complex formats slow down certain operations dramatically).

I think the feature would not add much additional complexity to the code.


The question is:  Is this a general need?  Are many people are using memoryviews
for bit-twiddling?
History
Date User Action Args
2014-10-16 21:46:19skrahsetrecipients: + skrah, pitrou, dabeaz
2014-10-16 21:46:19skrahsetmessageid: <1413495979.68.0.153517927097.issue15944@psf.upfronthosting.co.za>
2014-10-16 21:46:19skrahlinkissue15944 messages
2014-10-16 21:46:19skrahcreate