|
|
|
|
|
by veyron
5084 days ago
|
|
endianness only matters when you bother interpreting the data. The storage concept shouldn't care -- after all, 8 bytes is 8 bytes is 8 bytes. Struct needs it because it is interpreting data. unpack needs to know the endianness to correctly interpret numeric types, and pack needs to know the endianness to know how to serialize. FYI: the C way of doing this is byteswapping. |
|