Skip to content

Commit

Permalink
using ::isnan to avoid conflicts with std::isnan for C++11 build.
Browse files Browse the repository at this point in the history
Change-Id: I057b44eff04c3b0062a4fd4307ce6e4ca1eb952b
  • Loading branch information
liujisi committed Jun 18, 2015
1 parent e6484d3 commit a2b7937
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/google/protobuf/util/internal/utility.cc
Original file line number Diff line number Diff line change
Expand Up @@ -302,7 +302,7 @@ bool IsMap(const google::protobuf::Field& field,
string DoubleAsString(double value) {
if (value == std::numeric_limits<double>::infinity()) return "Infinity";
if (value == -std::numeric_limits<double>::infinity()) return "-Infinity";
if (isnan(value)) return "NaN";
if (::isnan(value)) return "NaN";

return SimpleDtoa(value);
}
Expand Down

0 comments on commit a2b7937

Please sign in to comment.