From 74de57c951aedebc5dfe26a27604353432392b98 Mon Sep 17 00:00:00 2001 From: "zhanyong.wan" Date: Thu, 28 Feb 2013 23:52:42 +0000 Subject: Fixes unused function warning on Mac, and fixes compatibility with newer GCC. git-svn-id: http://googletest.googlecode.com/svn/trunk@643 861a406c-534a-0410-8894-cb66d6ee9925 --- include/gtest/internal/gtest-port.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'include/gtest/internal/gtest-port.h') diff --git a/include/gtest/internal/gtest-port.h b/include/gtest/internal/gtest-port.h index f78994a..dc4fe0c 100644 --- a/include/gtest/internal/gtest-port.h +++ b/include/gtest/internal/gtest-port.h @@ -813,8 +813,8 @@ struct CompileAssert { }; #define GTEST_COMPILE_ASSERT_(expr, msg) \ - typedef ::testing::internal::CompileAssert<(bool(expr))> \ - msg[bool(expr) ? 1 : -1] + typedef ::testing::internal::CompileAssert<(static_cast(expr))> \ + msg[static_cast(expr) ? 1 : -1] GTEST_ATTRIBUTE_UNUSED_ // Implementation details of GTEST_COMPILE_ASSERT_: // -- cgit v1.2.3