QUERY · ISSUE
Add pop() in bytearray
enhancementpy-core
Request implementation of method pop() in type bytearray as implemented in CPython - like in type list.
CANDIDATE · PULL REQUEST
py/objarray: Add decode method to bytearray.
Reuse the implementation for bytes since it's exactly the same.
Also found this when working with msgpack where it gets used to get strings instead of bytes, which is too convenient not to use it (e.g. msgpack.unpackb(msgpack.packb('a')) returns b'a' without it). I don' think there is an easy way around here (like dynamically adding a method to a builtin type)?