MCPcopy Index your code
hub / github.com/RustPython/RustPython / _unpack_uint32

Function _unpack_uint32

Lib/importlib/_bootstrap_external.py:89–92  ·  view source on GitHub ↗

Convert 4 bytes in little-endian to an integer.

(data)

Source from the content-addressed store, hash-verified

87 return int.from_bytes(data, 'little')
88
89def _unpack_uint32(data):
90 """Convert 4 bytes in little-endian to an integer."""
91 assert len(data) == 4
92 return int.from_bytes(data, 'little')
93
94def _unpack_uint16(data):
95 """Convert 2 bytes in little-endian to an integer."""

Callers 2

_classify_pycFunction · 0.70
_validate_timestamp_pycFunction · 0.70

Calls 2

lenFunction · 0.85
from_bytesMethod · 0.45

Tested by

no test coverage detected