.TH "std::numeric_limits< _Tp >" 3cxx "Sun Jan 6 2013" "libstdc++" \" -*- nroff -*- .ad l .nh .SH NAME std::numeric_limits< _Tp > \- .SH SYNOPSIS .br .PP .PP Inherits \fBstd::__numeric_limits_base\fP\&. .PP Inherited by std::numeric_limits< const _Tp >, std::numeric_limits< const volatile _Tp >, and std::numeric_limits< volatile _Tp >\&. .SS "Static Public Member Functions" .in +1c .ti -1c .RI "static constexpr _Tp \fBdenorm_min\fP () _GLIBCXX_USE_NOEXCEPT" .br .ti -1c .RI "static constexpr _Tp \fBepsilon\fP () _GLIBCXX_USE_NOEXCEPT" .br .ti -1c .RI "static constexpr _Tp \fBinfinity\fP () _GLIBCXX_USE_NOEXCEPT" .br .ti -1c .RI "static constexpr _Tp \fBlowest\fP () noexcept" .br .ti -1c .RI "static constexpr _Tp \fBmax\fP () _GLIBCXX_USE_NOEXCEPT" .br .ti -1c .RI "static constexpr _Tp \fBmin\fP () _GLIBCXX_USE_NOEXCEPT" .br .ti -1c .RI "static constexpr _Tp \fBquiet_NaN\fP () _GLIBCXX_USE_NOEXCEPT" .br .ti -1c .RI "static constexpr _Tp \fBround_error\fP () _GLIBCXX_USE_NOEXCEPT" .br .ti -1c .RI "static constexpr _Tp \fBsignaling_NaN\fP () _GLIBCXX_USE_NOEXCEPT" .br .in -1c .SS "Static Public Attributes" .in +1c .ti -1c .RI "static constexpr int \fBdigits\fP" .br .ti -1c .RI "static constexpr int \fBdigits10\fP" .br .ti -1c .RI "static constexpr \fBfloat_denorm_style\fP \fBhas_denorm\fP" .br .ti -1c .RI "static constexpr bool \fBhas_denorm_loss\fP" .br .ti -1c .RI "static constexpr bool \fBhas_infinity\fP" .br .ti -1c .RI "static constexpr bool \fBhas_quiet_NaN\fP" .br .ti -1c .RI "static constexpr bool \fBhas_signaling_NaN\fP" .br .ti -1c .RI "static constexpr bool \fBis_bounded\fP" .br .ti -1c .RI "static constexpr bool \fBis_exact\fP" .br .ti -1c .RI "static constexpr bool \fBis_iec559\fP" .br .ti -1c .RI "static constexpr bool \fBis_integer\fP" .br .ti -1c .RI "static constexpr bool \fBis_modulo\fP" .br .ti -1c .RI "static constexpr bool \fBis_signed\fP" .br .ti -1c .RI "static constexpr bool \fBis_specialized\fP" .br .ti -1c .RI "static constexpr int \fBmax_digits10\fP" .br .ti -1c .RI "static constexpr int \fBmax_exponent\fP" .br .ti -1c .RI "static constexpr int \fBmax_exponent10\fP" .br .ti -1c .RI "static constexpr int \fBmin_exponent\fP" .br .ti -1c .RI "static constexpr int \fBmin_exponent10\fP" .br .ti -1c .RI "static constexpr int \fBradix\fP" .br .ti -1c .RI "static constexpr \fBfloat_round_style\fP \fBround_style\fP" .br .ti -1c .RI "static constexpr bool \fBtinyness_before\fP" .br .ti -1c .RI "static constexpr bool \fBtraps\fP" .br .in -1c .SH "Detailed Description" .PP .SS "templatestruct std::numeric_limits< _Tp >" Properties of fundamental types\&. This class allows a program to obtain information about the representation of a fundamental type on a given platform\&. For non-fundamental types, the functions will return 0 and the data members will all be \fCfalse\fP\&. .PP _GLIBCXX_RESOLVE_LIB_DEFECTS: DRs 201 and 184 (hi Gaby!) are noted, but not incorporated in this documented (yet)\&. .PP Definition at line 304 of file limits\&. .SH "Member Function Documentation" .PP .SS "template static constexpr _Tp \fBstd::numeric_limits\fP< _Tp >::denorm_min ()\fC [inline]\fP, \fC [static]\fP" .PP .nf The minimum positive denormalized value. For types where .fi .PP \fChas_denorm\fP is false, this is the minimum positive normalized value\&. .PP Definition at line 349 of file limits\&. .SS "template static constexpr _Tp \fBstd::numeric_limits\fP< _Tp >::epsilon ()\fC [inline]\fP, \fC [static]\fP" .PP .nf The @e machine @e epsilon: the difference between 1 and the least .fi .PP value greater than 1 that is representable\&. .PP Definition at line 325 of file limits\&. .PP Referenced by std::binomial_distribution< _IntType >::operator()(), and std::poisson_distribution< _IntType >::operator()()\&. .SS "template static constexpr _Tp \fBstd::numeric_limits\fP< _Tp >::infinity ()\fC [inline]\fP, \fC [static]\fP" The representation of positive infinity, if \fChas_infinity\fP\&. .PP Definition at line 333 of file limits\&. .SS "template static constexpr _Tp \fBstd::numeric_limits\fP< _Tp >::lowest ()\fC [inline]\fP, \fC [static]\fP, \fC [noexcept]\fP" A finite value x such that there is no other finite value y where y < x\&. .PP Definition at line 319 of file limits\&. .SS "template static constexpr _Tp \fBstd::numeric_limits\fP< _Tp >::max ()\fC [inline]\fP, \fC [static]\fP" The maximum finite value\&. .PP Definition at line 313 of file limits\&. .PP Referenced by std::normal_distribution< result_type >::max(), std::lognormal_distribution< _RealType >::max(), std::gamma_distribution< result_type >::max(), std::chi_squared_distribution< _RealType >::max(), std::cauchy_distribution< _RealType >::max(), std::fisher_f_distribution< _RealType >::max(), std::student_t_distribution< _RealType >::max(), std::bernoulli_distribution::max(), std::geometric_distribution< _IntType >::max(), std::negative_binomial_distribution< _IntType >::max(), std::poisson_distribution< _IntType >::max(), std::exponential_distribution< _RealType >::max(), std::weibull_distribution< _RealType >::max(), std::extreme_value_distribution< _RealType >::max(), std::tr2::dynamic_bitset< _WordT, _Alloc >::max_size(), std::independent_bits_engine< _RandomNumberEngine, __w, _UIntType >::operator()(), std::binomial_distribution< _IntType >::operator()(), and std::poisson_distribution< _IntType >::operator()()\&. .SS "template static constexpr _Tp \fBstd::numeric_limits\fP< _Tp >::min ()\fC [inline]\fP, \fC [static]\fP" .PP .nf The minimum finite value, or for floating types with .fi .PP denormalization, the minimum positive normalized value\&. .PP Definition at line 309 of file limits\&. .PP Referenced by std::normal_distribution< result_type >::min(), std::cauchy_distribution< _RealType >::min(), std::student_t_distribution< _RealType >::min(), std::bernoulli_distribution::min(), std::extreme_value_distribution< _RealType >::min(), and std::independent_bits_engine< _RandomNumberEngine, __w, _UIntType >::operator()()\&. .SS "template static constexpr _Tp \fBstd::numeric_limits\fP< _Tp >::quiet_NaN ()\fC [inline]\fP, \fC [static]\fP" .PP .nf The representation of a quiet Not a Number, .fi .PP if \fChas_quiet_NaN\fP\&. .PP Definition at line 338 of file limits\&. .SS "template static constexpr _Tp \fBstd::numeric_limits\fP< _Tp >::round_error ()\fC [inline]\fP, \fC [static]\fP" The maximum rounding error measurement (see LIA-1)\&. .PP Definition at line 329 of file limits\&. .SS "template static constexpr _Tp \fBstd::numeric_limits\fP< _Tp >::signaling_NaN ()\fC [inline]\fP, \fC [static]\fP" .PP .nf The representation of a signaling Not a Number, if .fi .PP \fChas_signaling_NaN\fP\&. .PP Definition at line 343 of file limits\&. .SH "Member Data Documentation" .PP .SS "constexpr int std::__numeric_limits_base::digits\fC [static]\fP, \fC [inherited]\fP" .PP .nf The number of @c radix digits that be represented without change: for .fi .PP integer types, the number of non-sign bits in the mantissa; for floating types, the number of \fCradix\fP digits in the mantissa\&. .PP Definition at line 201 of file limits\&. .SS "constexpr int std::__numeric_limits_base::digits10\fC [static]\fP, \fC [inherited]\fP" The number of base 10 digits that can be represented without change\&. .PP Definition at line 204 of file limits\&. .SS "constexpr \fBfloat_denorm_style\fP std::__numeric_limits_base::has_denorm\fC [static]\fP, \fC [inherited]\fP" See \fBstd::float_denorm_style\fP for more information\&. .PP Definition at line 258 of file limits\&. .SS "constexpr bool std::__numeric_limits_base::has_denorm_loss\fC [static]\fP, \fC [inherited]\fP" .PP .nf True if loss of accuracy is detected as a denormalization loss, .fi .PP rather than as an inexact result\&. [18\&.2\&.1\&.2]/42 .PP Definition at line 262 of file limits\&. .SS "constexpr bool std::__numeric_limits_base::has_infinity\fC [static]\fP, \fC [inherited]\fP" True if the type has a representation for positive infinity\&. .PP Definition at line 247 of file limits\&. .SS "constexpr bool std::__numeric_limits_base::has_quiet_NaN\fC [static]\fP, \fC [inherited]\fP" .PP .nf True if the type has a representation for a quiet (non-signaling) .fi .PP \fINot a Number\fP\&. .PP Definition at line 251 of file limits\&. .SS "constexpr bool std::__numeric_limits_base::has_signaling_NaN\fC [static]\fP, \fC [inherited]\fP" .PP .nf True if the type has a representation for a signaling .fi .PP \fINot a Number\fP\&. .PP Definition at line 255 of file limits\&. .SS "constexpr bool std::__numeric_limits_base::is_bounded\fC [static]\fP, \fC [inherited]\fP" .PP .nf True if the set of values representable by the type is .fi .PP finite\&. All built-in types are bounded, this member would be false for arbitrary precision types\&. [18\&.2\&.1\&.2]/54 .PP Definition at line 271 of file limits\&. .SS "constexpr bool std::__numeric_limits_base::is_exact\fC [static]\fP, \fC [inherited]\fP" .PP .nf True if the type uses an exact representation. All integer types are .fi .PP exact, but not all exact types are integer\&. For example, rational and fixed-exponent representations are exact but not integer\&. [18\&.2\&.1\&.2]/15 .PP Definition at line 223 of file limits\&. .SS "constexpr bool std::__numeric_limits_base::is_iec559\fC [static]\fP, \fC [inherited]\fP" .PP .nf True if-and-only-if the type adheres to the IEC 559 standard, also .fi .PP known as IEEE 754\&. (Only makes sense for floating point types\&.) .PP Definition at line 266 of file limits\&. .SS "constexpr bool std::__numeric_limits_base::is_integer\fC [static]\fP, \fC [inherited]\fP" True if the type is integer\&. Is this supposed to be \fIif the type is integral?\fP .PP Definition at line 217 of file limits\&. .SS "constexpr bool std::__numeric_limits_base::is_modulo\fC [static]\fP, \fC [inherited]\fP" .PP .nf True if the type is @e modulo, that is, if it is possible to add two .fi .PP positive numbers and have a result that wraps around to a third number that is less\&. Typically false for floating types, true for unsigned integers, and true for signed integers\&. .PP Definition at line 277 of file limits\&. .SS "constexpr bool std::__numeric_limits_base::is_signed\fC [static]\fP, \fC [inherited]\fP" True if the type is signed\&. .PP Definition at line 213 of file limits\&. .SS "constexpr bool std::__numeric_limits_base::is_specialized\fC [static]\fP, \fC [inherited]\fP" .PP .nf This will be true for all fundamental types (which have .fi .PP specializations), and false for everything else\&. .PP Definition at line 196 of file limits\&. .SS "constexpr int std::__numeric_limits_base::max_digits10\fC [static]\fP, \fC [inherited]\fP" .PP .nf The number of base 10 digits required to ensure that values which .fi .PP differ are always differentiated\&. .PP Definition at line 209 of file limits\&. .SS "constexpr int std::__numeric_limits_base::max_exponent\fC [static]\fP, \fC [inherited]\fP" .PP .nf The maximum positive integer such that @c radix raised to the power of .fi .PP (one less than that integer) is a representable finite floating point number\&. .PP Definition at line 240 of file limits\&. .SS "constexpr int std::__numeric_limits_base::max_exponent10\fC [static]\fP, \fC [inherited]\fP" .PP .nf The maximum positive integer such that 10 raised to that power is in .fi .PP the range of representable finite floating point numbers\&. .PP Definition at line 244 of file limits\&. .SS "constexpr int std::__numeric_limits_base::min_exponent\fC [static]\fP, \fC [inherited]\fP" .PP .nf The minimum negative integer such that @c radix raised to the power of .fi .PP (one less than that integer) is a normalized floating point number\&. .PP Definition at line 231 of file limits\&. .SS "constexpr int std::__numeric_limits_base::min_exponent10\fC [static]\fP, \fC [inherited]\fP" .PP .nf The minimum negative integer such that 10 raised to that power is in .fi .PP the range of normalized floating point numbers\&. .PP Definition at line 235 of file limits\&. .SS "constexpr int std::__numeric_limits_base::radix\fC [static]\fP, \fC [inherited]\fP" .PP .nf For integer types, specifies the base of the representation. For .fi .PP floating types, specifies the base of the exponent representation\&. .PP Definition at line 227 of file limits\&. .SS "constexpr \fBfloat_round_style\fP std::__numeric_limits_base::round_style\fC [static]\fP, \fC [inherited]\fP" .PP .nf See std::float_round_style for more information. This is only .fi .PP meaningful for floating types; integer types will all be round_toward_zero\&. .PP Definition at line 288 of file limits\&. .SS "constexpr bool std::__numeric_limits_base::tinyness_before\fC [static]\fP, \fC [inherited]\fP" True if tininess is detected before rounding\&. (see IEC 559) .PP Definition at line 283 of file limits\&. .SS "constexpr bool std::__numeric_limits_base::traps\fC [static]\fP, \fC [inherited]\fP" True if trapping is implemented for this type\&. .PP Definition at line 280 of file limits\&. .SH "Author" .PP Generated automatically by Doxygen for libstdc++ from the source code\&.