Fix RAISE_VARARGS bug

This commit is contained in:
Sahil Jain
2025-07-04 19:12:55 +05:30
parent 7d2039d24e
commit 8b0ea9450e
4 changed files with 16 additions and 2 deletions

View File

@@ -0,0 +1,9 @@
import struct <EOL>
def bytes_to_words ( b ) : <EOL>
<INDENT>
'Convert a byte string (little-endian) to a list of 32-bit words.' <EOL>
if len ( b ) % 4 != 0 : <EOL>
<INDENT>
raise ValueError ( 'Input bytes length must be a multiple of 4 for word conversion.' ) <EOL>
<OUTDENT>
return struct . unpack ( '<' + 'I' * ( len ( b ) // 4 ) , b ) <EOL>