Skip to content

Commit

Permalink
Fix C4127 warning in basic_writer<Range>::write_double
Browse files Browse the repository at this point in the history
  • Loading branch information
eliasdaler authored and vitaut committed Aug 17, 2018
1 parent 9de3121 commit 1840050
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions include/fmt/format.h
Original file line number Diff line number Diff line change
Expand Up @@ -2923,8 +2923,8 @@ void basic_writer<Range>::write_double(T value, const format_specs &spec) {
return write_inf_or_nan(handler.upper ? "INF" : "inf");

basic_memory_buffer<char_type> buffer;
if (FMT_USE_GRISU && sizeof(T) <= sizeof(double) &&
std::numeric_limits<double>::is_iec559) {
if (internal::const_check(FMT_USE_GRISU && sizeof(T) <= sizeof(double) &&
std::numeric_limits<double>::is_iec559)) {
internal::fp fp_value(static_cast<double>(value));
fp_value.normalize();
// Find a cached power of 10 close to 1 / fp_value.
Expand Down

0 comments on commit 1840050

Please sign in to comment.