fix compilation of Half in C++98 (issue introduced in previous commit)

(grafted from 26f552c18de48fa04f2a9a9a27540a7679328254
)
This commit is contained in:
Gael Guennebaud 2017-06-09 13:36:58 +02:00
parent e41713d52e
commit 8880be60fa

View File

@ -488,7 +488,7 @@ struct numeric_limits<Eigen::half> {
static const bool has_signaling_NaN = true;
static const float_denorm_style has_denorm = denorm_present;
static const bool has_denorm_loss = false;
std::float_round_style round_style = std::round_to_nearest;
static const std::float_round_style round_style = std::round_to_nearest;
static const bool is_iec559 = false;
static const bool is_bounded = false;
static const bool is_modulo = false;
@ -507,7 +507,7 @@ struct numeric_limits<Eigen::half> {
static Eigen::half lowest() { return Eigen::half_impl::raw_uint16_to_half(0xfbff); }
static Eigen::half (max)() { return Eigen::half_impl::raw_uint16_to_half(0x7bff); }
static Eigen::half epsilon() { return Eigen::half_impl::raw_uint16_to_half(0x0800); }
static Eigen::half round_error() { return epsilon()/2; }
static Eigen::half round_error() { return Eigen::half(0.5); }
static Eigen::half infinity() { return Eigen::half_impl::raw_uint16_to_half(0x7c00); }
static Eigen::half quiet_NaN() { return Eigen::half_impl::raw_uint16_to_half(0x7e00); }
static Eigen::half signaling_NaN() { return Eigen::half_impl::raw_uint16_to_half(0x7e00); }