Implementation of serde Serialize and Deserialize for the fixed library
Hi,
Would it be possible to implement serde::Serialize and Deserialize in a generic fashion in the library in a guaranteed value-preserving way?
Currently I've got an implementation which implements (de)serialization for a specific type by converting the value to f64, but this is obviously not ideal from both a correctness and performance perspective.
If it's not feasible to do it generically, do you have any ideas on how to improve my current solution?
Martijn
error[E0277]: the trait bound book::fixed::FixedI32<typenum::uint::UInt<typenum::uint::UInt<typenum::uint::UInt<typenum::uint::UInt<typenum::uint::UTerm, typenum::bit::B1>, typenum::bit::B1>, typenum::bit::B0>, typenum::bit::B0>>: serde::Serialize is not satisfied`