| 55 | } |
| 56 | |
| 57 | double WithPrecision(double value, uint8_t precision) |
| 58 | { |
| 59 | if (precision == 0) |
| 60 | return std::round(value); |
| 61 | |
| 62 | double const factor = math::PowUint(10.0, precision); |
| 63 | return std::round(value * factor) / factor; |
| 64 | } |
| 65 | } // namespace |
| 66 | |
| 67 | Distance::Distance() : Distance(-1.0) {} |
no test coverage detected