operations/
operations.rs

1use fixed2float::{to_Fx, FixedPoint};
2
3fn main() {
4  let fx1 = to_Fx(10.2, 5, 10, true).unwrap();
5  let fx2 = to_Fx(2.2, 2, 40, true).unwrap();
6
7  // println!("{:?}", fx1.unwrap() + fx2.unwrap());
8
9  let sum = fx1 + fx2;
10
11  println!("{:?} {}", sum, sum.eval());
12  println!("{:?} {}", sum.m, sum.b);
13}