Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ClampUint32ToUint16 ¶
ClampUint32ToUint16 safely converts uint32 to uint16, clamping to 65535 if overflow.
func ParseUint32 ¶
func SafeIntToInt32 ¶
SafeIntToInt32 converts int to int32, clamping to int32 max/min.
func SafeIntToUint16 ¶
SafeIntToUint16 safely converts int to uint16, clamping to 0-65535.
func SafeIntToUint32 ¶
SafeIntToUint32 converts int to uint32, clamping negative values to 0.
func SafeIntToUint64 ¶
SafeIntToUint64 converts int to uint64, assuming non-negative input (e.g., from Read()).
func Safeu32ToInt ¶
Safeu32ToInt converts uint32 to int, returning 0 if overflow would occur.
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.