summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorkosak@google.com <kosak@google.com@861a406c-534a-0410-8894-cb66d6ee9925>2015-07-14 22:44:39 +0000
committerkosak@google.com <kosak@google.com@861a406c-534a-0410-8894-cb66d6ee9925>2015-07-14 22:44:39 +0000
commitf3aba5a9f6b3e975740de5a117935243cb18671c (patch)
treec248402689dcf4ec01c363b362f96b0e67013ad2 /include
parenteb80d05869807682f8f59b8f3251384a39adf16a (diff)
downloadgoogletest-f3aba5a9f6b3e975740de5a117935243cb18671c.tar.gz
Move the selection of the flag saver implementation into gtest-port.h and
custom/gtest-port.h. git-svn-id: http://googletest.googlecode.com/svn/trunk@723 861a406c-534a-0410-8894-cb66d6ee9925
Diffstat (limited to 'include')
-rw-r--r--include/gtest/gtest.h3
-rw-r--r--include/gtest/internal/gtest-port.h2
2 files changed, 3 insertions, 2 deletions
diff --git a/include/gtest/gtest.h b/include/gtest/gtest.h
index 71d552e..919df65 100644
--- a/include/gtest/gtest.h
+++ b/include/gtest/gtest.h
@@ -452,8 +452,7 @@ class GTEST_API_ Test {
// internal method to avoid clashing with names used in user TESTs.
void DeleteSelf_() { delete this; }
- // Uses a GTestFlagSaver to save and restore all Google Test flags.
- const internal::GTestFlagSaver* const gtest_flag_saver_;
+ const internal::scoped_ptr< GTEST_FLAG_SAVER_ > gtest_flag_saver_;
// Often a user misspells SetUp() as Setup() and spends a long time
// wondering why it is never called by Google Test. The declaration of
diff --git a/include/gtest/internal/gtest-port.h b/include/gtest/internal/gtest-port.h
index 83fa75d..b3830c5 100644
--- a/include/gtest/internal/gtest-port.h
+++ b/include/gtest/internal/gtest-port.h
@@ -2418,6 +2418,8 @@ typedef TypeWithSize<8>::Int TimeInMillis; // Represents time in milliseconds.
#endif // !defined(GTEST_FLAG)
#if !defined(GTEST_DECLARE_bool_)
+# define GTEST_FLAG_SAVER_ ::testing::internal::GTestFlagSaver
+
// Macros for declaring flags.
# define GTEST_DECLARE_bool_(name) GTEST_API_ extern bool GTEST_FLAG(name)
# define GTEST_DECLARE_int32_(name) \