about summary refs log tree commit diff
path: root/library/std/src/f32.rs
AgeCommit message (Collapse)AuthorLines
2021-07-29Fix may not to appropriate might not or must notAli Malik-1/+1
2021-07-07Clarify behaviour of f64 and f32::sqrt when argument is negative zerocyberia-1/+3
2021-06-13Change tracking issueltdk-1/+1
2021-06-13More lerp tests, altering lerp docsltdk-13/+21
2021-06-01Add lerp methodltdk-0/+28
2021-02-26doc: cube root, not cubic rootTrevor Spiteri-1/+1
Like we say square root, not quadratic root.
2021-01-20Deprecate-in-future the constants superceded by RFC 2700bstrie-13/+10
2020-12-19Auto merge of #79473 - m-ou-se:clamp-in-core, r=m-ou-sebors-35/+0
Move {f32,f64}::clamp to core. `clamp` was recently stabilized (tracking issue: https://github.com/rust-lang/rust/issues/44095). But although `Ord::clamp` was added in `core` (because `Ord` is in `core`), the versions for the `f32` and `f64` primitives were added in `std` (together with `floor`, `sin`, etc.), not in `core` (together with `min`, `max`, `from_bits`, etc.). This change moves them to `core`, such that `clamp` on floats is available in `no_std` programs as well.
2020-12-10Rollup merge of #77027 - termhn:mul_add_doc_change, r=m-ou-seTyler Mandry-2/+4
Improve documentation for `std::{f32,f64}::mul_add` Makes it more clear that performance improvement is not guaranteed when using FMA, even when the target architecture supports it natively.
2020-11-27Move {f32,f64}::clamp to core.Mara Bos-35/+0
2020-11-22Auto merge of #77872 - Xaeroxe:stabilize-clamp, r=scottmcmbors-2/+1
Stabilize clamp Tracking issue: https://github.com/rust-lang/rust/issues/44095 Clamp has been merged and unstable for about a year and a half now. How do we feel about stabilizing this?
2020-11-20We missed 1.49.0, so bump version to 1.50.0Jacob Kiesel-1/+1
2020-10-31Rollup merge of #77099 - tspiteri:exp_m1-examples, r=m-ou-seMara Bos-8/+10
make exp_m1 and ln_1p examples more representative of use With this PR, the examples for `exp_m1` would fail if `x.exp() - 1.0` is used instead of `x.exp_m1()`, and the examples for `ln_1p` would fail if `(x + 1.0).ln()` is used instead of `x.ln_1p()`.
2020-10-29Improve wording of `core::ptr::drop_in_place` docsCamelid-1/+1
And two small intra-doc link conversions in `std::{f32, f64}`.
2020-10-13generalize warningGray Olson-4/+3
2020-10-12Stabilize clampJacob Kiesel-2/+1
2020-09-23make ln_1p examples more representative of useTrevor Spiteri-4/+5
With this commit, the examples for ln_1p would fail if (x + 1.0).ln() is used instead of x.ln_1p().
2020-09-23make exp_m1 examples more representative of useTrevor Spiteri-4/+5
With this commit, the examples for exp_m1 would fail if x.exp() - 1.0 is used instead of x.exp_m1().
2020-09-21Edit documentation for `std::{f32,f64}::mul_add`.Gray Olson-2/+5
Makes it more clear that a performance improvement is not guaranteed when using FMA, even when the target architecture supports it natively.
2020-08-31std: move "mod tests/benches" to separate filesLzu Tao-763/+3
Also doing fmt inplace as requested.
2020-07-27mv std libs to library/mark-0/+1674