std::float_round_style(3)
β¨ std::float_round_style β¨π
okay bestie, real talk: this page comes from the C++ Standard Libary (that's the manual name, we don't argue with it), and it's literally about an enum that tells you which way floating-point math rounds when a result gets stored in a floating-point object. no cap, it's giving "tiny but important" energy π
β¨ NAME β¨
std::float_round_style β std::float_round_style (yes she named herself, main character behavior π)
π¦ Synopsis π¦
Defined in header <limits>
enum float_round_style {
round_indeterminate = -1,
round_toward_zero = 0,
round_to_nearest = 1,
round_toward_infinity = 2,
round_toward_neg_infinity = 3
};
πΈ Description πΈ
so like, enumeration constants of type std::float_round_style indicate the rounding style used by floating-point arithmetic whenever a result of an expression is stored in an object of a floating-point type. the values are:
π Enumeration constants π
std::round_indeterminateβ rounding style cannot be determined πstd::round_toward_zeroβ rounding toward zerostd::round_to_nearestβ rounding toward nearest representable valuestd::round_toward_infinityβ rounding toward positive infinitystd::round_toward_neg_infinityβ rounding toward negative infinity
π See also π
round_styleβ identifies the rounding style used by the type[static](public static member constant)FE_DOWNWARD,FE_TONEAREST,FE_TOWARDZERO,FE_UPWARD(C++11) β floating-point rounding direction (macro constant)
source/version: http://cppreference.com Β· date: 2024.06.10 β stay rounding, bestie, you ate this one π«Άππ₯
π¦ where this page comes from
- nixpkgs unstable: stdman 2024.07.05
- opensuse-leap 16.0: stdman 2024.07.05-bp160.1.9 Β· MIT
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms