From 51a184058dce16539cab86c4db94e259bc9aca99 Mon Sep 17 00:00:00 2001 From: David Blaikie Date: Wed, 26 Feb 2014 19:12:28 +0000 Subject: Use the overloaded std::abs rather than C's abs(int) to address Clang's -Wabsolute-value llvm-svn: 202286 --- llvm/unittests/Support/TimeValueTest.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'llvm/unittests/Support/TimeValueTest.cpp') diff --git a/llvm/unittests/Support/TimeValueTest.cpp b/llvm/unittests/Support/TimeValueTest.cpp index e0368d3..8058812 100644 --- a/llvm/unittests/Support/TimeValueTest.cpp +++ b/llvm/unittests/Support/TimeValueTest.cpp @@ -17,7 +17,7 @@ namespace { TEST(TimeValue, time_t) { sys::TimeValue now = sys::TimeValue::now(); time_t now_t = time(NULL); - EXPECT_TRUE(abs(static_cast(now_t - now.toEpochTime())) < 2); + EXPECT_TRUE(std::abs(static_cast(now_t - now.toEpochTime())) < 2); } TEST(TimeValue, Win32FILETIME) { -- cgit v1.1