pw_string: Remove implicit double promotions Cherry-pick from https://pigweed-review.googlesource.com/c/pigweed/pigweed/+/67422 Change-Id: I0c92d22e8941f4802abf574a794a989f9b4436a1
diff --git a/pw_string/type_to_string.cc b/pw_string/type_to_string.cc index 3475b12..ab58a52 100644 --- a/pw_string/type_to_string.cc +++ b/pw_string/type_to_string.cc
@@ -153,7 +153,7 @@ if (std::isfinite(value) && std::abs(value) < static_cast<float>(std::numeric_limits<int64_t>::max())) { - return IntToString<int64_t>(::round(value), buffer); + return IntToString<int64_t>(roundf(value), buffer); } // Otherwise, print inf or NaN, if they fit.