[go: up one dir, main page]

[][src]Module fraction::prelude

Predefines some types for the most common use cases

You should consider this module as a list of shortcuts, and not as the list of only available types. The actual workhorses are a part of the Public API and you are encouraged to use them straightforwardly whenever you may feel necessary.

Long story short, you may compose your own types with these:

Type Definitions

BigDecimal

Heap allocated BigUint for numerics and usize for precision

BigFraction

Fraction consisting from two BigUint numbers

Decimal

Basic Decimal based on 2 u64 numbers and one u8 for precision. Able to keep up to 19 digits in the number (including both sides across the floating point).

DynaDecimal

Dynamically growing decimal

DynaFraction

Fraction using T as the base type for numerator and denominator

Fraction

Fraction consisting from two u64 numbers