std::numeric_limits::denorm_min
De cppreference.com
|
|
This page has been machine-translated from the English version of the wiki using Google Translate.
The translation may contain errors and awkward wording. Hover over text to see the original version. You can help to fix errors and improve the translation. For instructions click here. |
<metanoindex/>
<tbody> </tbody> static T denorm_min() |
(avant C++11) | |
static constexpr T denorm_min() |
(depuis C++11) | |
Retourne le valeur inférieure à la normale minimum positive de la
T type, s'il std::numeric_limits<T>::has_denorm != std::denorm_absent, sinon retourne std::numeric_limits<T>::min(). N'a de sens que pour les types à virgule flottante .Original:
Returns the minimum positive valeur inférieure à la normale of the type
T, if std::numeric_limits<T>::has_denorm != std::denorm_absent, otherwise returns std::numeric_limits<T>::min(). Only meaningful for floating-point types.The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
You can help to correct and verify the translation. Click here for instructions.
Retourne la valeur
T
|
std::numeric_limits<T>::denorm_min()
|
| /* non-specialized */ | T();
|
bool
|
false
|
char
|
0
|
signed char
|
0
|
unsigned char
|
0
|
wchar_t
|
0
|
char16_t
|
0
|
char32_t
|
0
|
short
|
0
|
unsigned short
|
0
|
int
|
0
|
unsigned int
|
0
|
long
|
0
|
unsigned long
|
0
|
long long
|
0
|
unsigned long long
|
0
|
float
|
2-149 if std::numeric_limits<float>::is_iec559 == true
|
double
|
2-1074 if std::numeric_limits<double>::is_iec559 == true
|
long double
|
/ * Défini par l'implémentation * /
Original: /* implementation-defined */ The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. |
Exceptions
Exemple
Demonstates la structure sous-jacente de la mèche denorm_min ()
Original:
Demonstates the underlying bit structure of the denorm_min()
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
You can help to correct and verify the translation. Click here for instructions.
#include <cstdint>
#include <limits>
#include <cassert>
int main()
{
// the smallest subnormal value has sign bit = 0, exponent = 0
// and only the least significant bit of the fraction is 1
uint32_t denorm_bits = 0x0001;
float denorm_float = reinterpret_cast<float&>(denorm_bits);
assert(denorm_float == std::numeric_limits<float>::denorm_min());
}
Voir aussi
[ statique ]Original: static The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. |
renvoie la plus petite valeur finie du type donné Original: returns the smallest finite value of the given type The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. (fonction membre publique statique) |
[ statique ]Original: static The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. |
identifie le style utilisé par la dénormalisation du type à virgule flottante Original: identifies the denormalization style used by the floating-point type The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. (constante membre statique publique) |
[ statique ] (C++11)Original: static The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. |
renvoie la plus petite valeur finie du type donné Original: returns the lowest finite value of the given type The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. (fonction membre publique statique) |