implicit-predicates-core
The no_std, dependency-free core of
implicit-predicates: the
arithmetic building blocks shared by the predicates and by generated code.
Status: early development. The API is incomplete and may change.
Currently it provides:
Sign, the result type of every predicate;eft, error-free transformations: floating-point sums and products together with their exact rounding errors;expansion, exact values represented as sums off64components, with exact addition, subtraction, scaling and sign, all without allocation;Scratch, a bump arena over a borrowed buffer that holds the expansions of a computation and runs those operations on them, as well as the exact product of two expansions.
The exact products require operands in a documented range, the product
domain (eft::in_product_domain); debug builds check it.
The optional alloc feature adds Scratch::growable, an arena that grows on
the heap so the exact arithmetic can always complete. Without it the crate
never allocates.
Most users should depend on implicit-predicates instead.
License
Licensed under either of Apache License, Version 2.0 or MIT license, at your option.