diff options
| author | bors <bors@rust-lang.org> | 2018-07-12 12:50:13 +0000 |
|---|---|---|
| committer | bors <bors@rust-lang.org> | 2018-07-12 12:50:13 +0000 |
| commit | 7db82ccd765cbfe55c3d8a2c434bc6f9b986843d (patch) | |
| tree | 41bda55edea65f5ef3f02b198ce2984b97e666e2 /src/libcore | |
| parent | d334027c58060449cc45b8e5cc37dd51ca077d30 (diff) | |
| parent | a7c2c68b135b40666bda030315007c29ce197901 (diff) | |
| download | rust-7db82ccd765cbfe55c3d8a2c434bc6f9b986843d.tar.gz rust-7db82ccd765cbfe55c3d8a2c434bc6f9b986843d.zip | |
Auto merge of #52303 - kennytm:rollup, r=kennytm
Rollup of 9 pull requests Successful merges: - #51816 (bootstrap: write texts to a .tmp file first for atomicity) - #51912 (impl Clone for Box<CStr>, Box<OsStr>, Box<Path>) - #52164 (use proper footnote syntax for references) - #52220 (Deny bare trait objects in `src/bootstrap`) - #52276 (rustc: Verify #[proc_macro] is only a word) - #52277 (Uncapitalize "If") - #52287 (Deny bare trait objects in src/librustc_resolve) - #52295 (Deny bare trait objects in src/libsyntax_ext) - #52298 (make reference to dirs crate clickable in terminals) Failed merges: r? @ghost
Diffstat (limited to 'src/libcore')
| -rw-r--r-- | src/libcore/num/flt2dec/strategy/dragon.rs | 11 | ||||
| -rw-r--r-- | src/libcore/num/flt2dec/strategy/grisu.rs | 13 |
2 files changed, 11 insertions, 13 deletions
diff --git a/src/libcore/num/flt2dec/strategy/dragon.rs b/src/libcore/num/flt2dec/strategy/dragon.rs index 9c9e531c593..aa6a08cb205 100644 --- a/src/libcore/num/flt2dec/strategy/dragon.rs +++ b/src/libcore/num/flt2dec/strategy/dragon.rs @@ -8,12 +8,11 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -/*! -Almost direct (but slightly optimized) Rust translation of Figure 3 of \[1\]. - -\[1\] Burger, R. G. and Dybvig, R. K. 1996. Printing floating-point numbers - quickly and accurately. SIGPLAN Not. 31, 5 (May. 1996), 108-116. -*/ +//! Almost direct (but slightly optimized) Rust translation of Figure 3 of "Printing +//! Floating-Point Numbers Quickly and Accurately"[^1]. +//! +//! [^1]: Burger, R. G. and Dybvig, R. K. 1996. Printing floating-point numbers +//! quickly and accurately. SIGPLAN Not. 31, 5 (May. 1996), 108-116. use cmp::Ordering; diff --git a/src/libcore/num/flt2dec/strategy/grisu.rs b/src/libcore/num/flt2dec/strategy/grisu.rs index 5c023a191db..f33186e59c2 100644 --- a/src/libcore/num/flt2dec/strategy/grisu.rs +++ b/src/libcore/num/flt2dec/strategy/grisu.rs @@ -8,13 +8,12 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -/*! -Rust adaptation of Grisu3 algorithm described in \[1\]. It uses about -1KB of precomputed table, and in turn, it's very quick for most inputs. - -\[1\] Florian Loitsch. 2010. Printing floating-point numbers quickly and - accurately with integers. SIGPLAN Not. 45, 6 (June 2010), 233-243. -*/ +//! Rust adaptation of the Grisu3 algorithm described in "Printing Floating-Point Numbers Quickly +//! and Accurately with Integers"[^1]. It uses about 1KB of precomputed table, and in turn, it's +//! very quick for most inputs. +//! +//! [^1]: Florian Loitsch. 2010. Printing floating-point numbers quickly and +//! accurately with integers. SIGPLAN Not. 45, 6 (June 2010), 233-243. use num::diy_float::Fp; use num::flt2dec::{Decoded, MAX_SIG_DIGITS, round_up}; |
