mp_rational: support for serialization.