命名空间
变体
操作

std::numeric_limits<T>::has_denorm

来自 cppreference.cn
 
 
 
 
 
static const std::float_denorm_style has_denorm;
(直到 C++11)
static constexpr std::float_denorm_style has_denorm;
(自 C++11 起)
(在 C++23 中弃用)

std::numeric_limits<T>::has_denorm 的值标识了支持 subnormal values 的浮点类型。

[编辑] 标准特化

T std::numeric_limits<T>::has_denorm 的值
/* 非特化 */ std::denorm_absent
bool std::denorm_absent
char std::denorm_absent
signed char std::denorm_absent
unsigned char std::denorm_absent
wchar_t std::denorm_absent
char8_t (since C++20) std::denorm_absent
char16_t (since C++11) std::denorm_absent
char32_t (since C++11) std::denorm_absent
short std::denorm_absent
unsigned short std::denorm_absent
int std::denorm_absent
unsigned int std::denorm_absent
long std::denorm_absent
unsigned long std::denorm_absent
long long (since C++11) std::denorm_absent
unsigned long long (since C++11) std::denorm_absent
float 通常为 std::denorm_present
double 通常为 std::denorm_present
long double 通常为 std::denorm_present

[编辑] 参见

[静态]
返回给定浮点类型的最小正次正规值
(public static member function) [编辑]
指示浮点反常化模式
(enum) [编辑]