rust_decimal/
ops.rs

1// This code (in fact, this library) is heavily inspired by the dotnet Decimal number library
2// implementation. Consequently, a huge thank you for to all the contributors to that project
3// whose work has also inspired the solutions found here.
4
5pub(crate) mod array;
6
7#[cfg(feature = "legacy-ops")]
8mod legacy;
9#[cfg(feature = "legacy-ops")]
10pub(crate) use legacy::{add_impl, cmp_impl, div_impl, mul_impl, rem_impl, sub_impl};
11
12#[cfg(not(feature = "legacy-ops"))]
13mod add;
14#[cfg(not(feature = "legacy-ops"))]
15mod cmp;
16#[cfg(not(feature = "legacy-ops"))]
17pub(in crate::ops) mod common;
18#[cfg(not(feature = "legacy-ops"))]
19mod div;
20#[cfg(not(feature = "legacy-ops"))]
21mod mul;
22#[cfg(not(feature = "legacy-ops"))]
23mod rem;
24
25#[cfg(not(feature = "legacy-ops"))]
26pub(crate) use add::{add_impl, sub_impl};
27#[cfg(not(feature = "legacy-ops"))]
28pub(crate) use cmp::cmp_impl;
29#[cfg(not(feature = "legacy-ops"))]
30pub(crate) use div::div_impl;
31#[cfg(not(feature = "legacy-ops"))]
32pub(crate) use mul::mul_impl;
33#[cfg(not(feature = "legacy-ops"))]
34pub(crate) use rem::rem_impl;