1// The code in this module is derived from the `lexical` crate by @Alexhuszagh
2// which the author condensed into this minimal subset for use in serde_json.
3// For the serde_json use case we care more about reliably round tripping all
4// possible floating point values than about parsing any arbitrarily long string
5// of digits with perfect accuracy, as the latter would take a high cost in
6// compile time and performance.
7//
8// Dual licensed as MIT and Apache 2.0 just like the rest of serde_json, but
9// copyright Alexander Huszagh.
10
11//! Fast, minimal float-parsing algorithm.
12
13// MODULES
14pub(crate) mod algorithm;
15mod bhcomp;
16mod bignum;
17mod cached;
18mod cached_float80;
19mod digit;
20mod errors;
21pub(crate) mod exponent;
22pub(crate) mod float;
23mod large_powers;
24pub(crate) mod math;
25pub(crate) mod num;
26pub(crate) mod parse;
27pub(crate) mod rounding;
28mod shift;
29mod small_powers;
30
31#[cfg(limb_width_32)]
32mod large_powers32;
33
34#[cfg(limb_width_64)]
35mod large_powers64;
36
37// API
38pub use self::parse::{parse_concise_float, parse_truncated_float};
39