diff options
Diffstat (limited to 'utils/unittest/googletest/src')
-rw-r--r-- | utils/unittest/googletest/src/gtest-death-test.cc | 6 | ||||
-rw-r--r-- | utils/unittest/googletest/src/gtest-internal-inl.h | 2 | ||||
-rw-r--r-- | utils/unittest/googletest/src/gtest-port.cc | 14 | ||||
-rw-r--r-- | utils/unittest/googletest/src/gtest.cc | 10 |
4 files changed, 31 insertions, 1 deletions
diff --git a/utils/unittest/googletest/src/gtest-death-test.cc b/utils/unittest/googletest/src/gtest-death-test.cc index 82453f20fd..314dba2116 100644 --- a/utils/unittest/googletest/src/gtest-death-test.cc +++ b/utils/unittest/googletest/src/gtest-death-test.cc @@ -300,6 +300,9 @@ DeathTest::DeathTest() { } } +// Pin the vtable to this file. +DeathTest::~DeathTest() {} + // Creates and returns a death test by dispatching to the current // death test factory. bool DeathTest::Create(const char* statement, const RE* regex, @@ -1091,6 +1094,9 @@ bool DefaultDeathTestFactory::Create(const char* statement, const RE* regex, return true; } +// Pin the vtable to this file. +DeathTestFactory::~DeathTestFactory() {} + // Splits a given string on a given delimiter, populating a given // vector with the fields. GTEST_HAS_DEATH_TEST implies that we have // ::std::string, so we can use it here. diff --git a/utils/unittest/googletest/src/gtest-internal-inl.h b/utils/unittest/googletest/src/gtest-internal-inl.h index 6554cfc07e..1bae630127 100644 --- a/utils/unittest/googletest/src/gtest-internal-inl.h +++ b/utils/unittest/googletest/src/gtest-internal-inl.h @@ -408,7 +408,7 @@ GTEST_API_ FilePath GetCurrentExecutableName(); class OsStackTraceGetterInterface { public: OsStackTraceGetterInterface() {} - virtual ~OsStackTraceGetterInterface() {} + virtual ~OsStackTraceGetterInterface(); // Returns the current OS stack trace as a String. Parameters: // diff --git a/utils/unittest/googletest/src/gtest-port.cc b/utils/unittest/googletest/src/gtest-port.cc index 745956247a..94fc57f89b 100644 --- a/utils/unittest/googletest/src/gtest-port.cc +++ b/utils/unittest/googletest/src/gtest-port.cc @@ -746,5 +746,19 @@ const char* StringFromGTestEnv(const char* flag, const char* default_value) { return value == NULL ? default_value : value; } +// Pin the vtables to this file. +#if GTEST_HAS_PTHREAD +ThreadWithParamBase::~ThreadWithParamBase() {} +ThreadLocalValueHolderBase::~ThreadLocalValueHolderBase() {} +#endif +TestFactoryBase::~TestFactoryBase() {} + } // namespace internal } // namespace testing + +// Pin the vtable to this file. +#if !GTEST_NO_LLVM_RAW_OSTREAM +namespace llvm { +void convertible_fwd_ostream::anchor() {} +} +#endif diff --git a/utils/unittest/googletest/src/gtest.cc b/utils/unittest/googletest/src/gtest.cc index 9891928048..bf850c6cd9 100644 --- a/utils/unittest/googletest/src/gtest.cc +++ b/utils/unittest/googletest/src/gtest.cc @@ -4863,4 +4863,14 @@ void InitGoogleTest(int* argc, wchar_t** argv) { internal::InitGoogleTestImpl(argc, argv); } +// Pin the vtables to this file. +Environment::~Environment() {} +TestPartResultReporterInterface::~TestPartResultReporterInterface() {} +TestEventListener::~TestEventListener() {} +void EmptyTestEventListener::anchor() {} +namespace internal { +OsStackTraceGetterInterface::~OsStackTraceGetterInterface() {} +ParameterizedTestCaseInfoBase::~ParameterizedTestCaseInfoBase() {} +} + } // namespace testing |