From ba99a04be2d522015670b0c89761604a78b1ea5b Mon Sep 17 00:00:00 2001 From: Peter Collingbourne Date: Thu, 11 Jan 2018 19:36:25 -0800 Subject: [PATCH] Check whether _MSC_VER is defined when detecting presence of cxxabi.h under libc++. If _MSC_VER is defined, it means that we are using the Microsoft ABI, so cxxabi.h (which is associated with the Itanium ABI) will not be available. --- googletest/include/gtest/internal/gtest-port.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/googletest/include/gtest/internal/gtest-port.h b/googletest/include/gtest/internal/gtest-port.h index 58ab7fdf..01ad5dac 100644 --- a/googletest/include/gtest/internal/gtest-port.h +++ b/googletest/include/gtest/internal/gtest-port.h @@ -980,7 +980,7 @@ using ::std::tuple_size; #endif // _LIBCPP_VERSION is defined by the libc++ library from the LLVM project. -#if defined(__GLIBCXX__) || defined(_LIBCPP_VERSION) +#if defined(__GLIBCXX__) || (defined(_LIBCPP_VERSION) && !defined(_MSC_VER)) # define GTEST_HAS_CXXABI_H_ 1 #else # define GTEST_HAS_CXXABI_H_ 0