pub unsafe extern "C" fn mp_int_to_unsigned(
    z: mp_int,
    buf: *mut c_uchar,
    limit: c_int
) -> mp_result
Expand description

Converts the magnitude of z to unsigned binary, writing at most limit bytes into the given buf. The sign of z is ignored, but z is not modified. Returns MP_TRUNC if the buffer limit was too small to contain the whole value. If this occurs, the contents of buf will be effectively garbage, as the function uses the buffer as scratch space during conversion.

The binary representation of z is in base-256 with digits ordered from most significant to least significant (network byte ordering).