[issue36839] Support the buffer protocol in code objects

Brett Cannon report at bugs.python.org
Thu May 30 16:12:34 EDT 2019


Brett Cannon <brett at python.org> added the comment:

I agree with Eric. While I understand what Serhiy is saying about code objects being more than a bytearray of bytecode, the buffer protocol is still a view on an object, and that view happens to be for a subset which I think is acceptable as I think of what a buffer of a code object would be other than the bytecode.

I also think read-only is a good enough guarantee. We're talking low-level stuff here and if anyone were to muck with this stuff they are already playing with fire.

----------
nosy: +brett.cannon

_______________________________________
Python tracker <report at bugs.python.org>
<https://bugs.python.org/issue36839>
_______________________________________


More information about the Python-bugs-list mailing list