[issue45782] Bug in struct.pack
Steven D'Aprano
report at bugs.python.org
Thu Nov 11 05:43:12 EST 2021
Steven D'Aprano <steve+python at pearwood.info> added the comment:
The behaviour is correct. You have tripped over the ASCII representation of bytes. In ASCII, 119 (or in hex, 0x77) is displayed as 'w'.
>>> b'\x77\x00\x00\x00'
b'w\x00\x00\x00'
----------
nosy: +steven.daprano
resolution: -> not a bug
stage: -> resolved
status: open -> closed
_______________________________________
Python tracker <report at bugs.python.org>
<https://bugs.python.org/issue45782>
_______________________________________
More information about the Python-bugs-list
mailing list