summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorkosak <kosak@google.com>2015-04-28 21:43:13 (GMT)
committerkosak <kosak@google.com>2015-04-28 21:43:13 (GMT)
commit5c996c64665ff9826100f0f0fb055b7c883277bb (patch)
treebb82abdf383c3d759390a51180073ef31736a438 /src
parent1d53731f2c210557caab5660dbe2c578dce6114f (diff)
downloadgoogletest-5c996c64665ff9826100f0f0fb055b7c883277bb.zip
googletest-5c996c64665ff9826100f0f0fb055b7c883277bb.tar.gz
googletest-5c996c64665ff9826100f0f0fb055b7c883277bb.tar.bz2
Make an int64->double conversion explicit to silence -Wconversion.
Addresses issue #173: https://code.google.com/p/googlemock/issues/detail?id=173
Diffstat (limited to 'src')
-rw-r--r--src/gtest.cc2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/gtest.cc b/src/gtest.cc
index 7fd5f29..bcbbf53 100644
--- a/src/gtest.cc
+++ b/src/gtest.cc
@@ -3501,7 +3501,7 @@ std::string XmlUnitTestResultPrinter::RemoveInvalidXmlCharacters(
// Formats the given time in milliseconds as seconds.
std::string FormatTimeInMillisAsSeconds(TimeInMillis ms) {
::std::stringstream ss;
- ss << ms/1000.0;
+ ss << (static_cast<double>(ms) * 1e-3);
return ss.str();
}