Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
yangql
googletest
Commits
5145e0fb
Commit
5145e0fb
authored
Dec 09, 2008
by
shiqian
Browse files
Use <tuple> instead of <tr1/tuple> when the compiler is not gcc, to conform with the TR1 spec.
parent
2051d2cc
Changes
6
Show whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
17 additions
and
20 deletions
+17
-20
include/gtest/gtest-param-test.h
include/gtest/gtest-param-test.h
+0
-3
include/gtest/gtest-param-test.h.pump
include/gtest/gtest-param-test.h.pump
+0
-3
include/gtest/internal/gtest-param-util-generated.h
include/gtest/internal/gtest-param-util-generated.h
+0
-4
include/gtest/internal/gtest-param-util-generated.h.pump
include/gtest/internal/gtest-param-util-generated.h.pump
+0
-4
include/gtest/internal/gtest-port.h
include/gtest/internal/gtest-port.h
+17
-2
test/gtest-param-test_test.cc
test/gtest-param-test_test.cc
+0
-4
No files found.
include/gtest/gtest-param-test.h
View file @
5145e0fb
...
@@ -156,9 +156,6 @@ INSTANTIATE_TEST_CASE_P(AnotherInstantiationName, FooTest, ValuesIn(pets));
...
@@ -156,9 +156,6 @@ INSTANTIATE_TEST_CASE_P(AnotherInstantiationName, FooTest, ValuesIn(pets));
#include <gtest/internal/gtest-internal.h>
#include <gtest/internal/gtest-internal.h>
#include <gtest/internal/gtest-param-util.h>
#include <gtest/internal/gtest-param-util.h>
#include <gtest/internal/gtest-param-util-generated.h>
#include <gtest/internal/gtest-param-util-generated.h>
#ifdef GTEST_HAS_COMBINE
#include <tr1/tuple>
#endif // GTEST_HAS_COMBINE
namespace
testing
{
namespace
testing
{
...
...
include/gtest/gtest-param-test.h.pump
View file @
5145e0fb
...
@@ -157,9 +157,6 @@ INSTANTIATE_TEST_CASE_P(AnotherInstantiationName, FooTest, ValuesIn(pets));
...
@@ -157,9 +157,6 @@ INSTANTIATE_TEST_CASE_P(AnotherInstantiationName, FooTest, ValuesIn(pets));
#include <gtest/internal/gtest-internal.h>
#include <gtest/internal/gtest-internal.h>
#include <gtest/internal/gtest-param-util.h>
#include <gtest/internal/gtest-param-util.h>
#include <gtest/internal/gtest-param-util-generated.h>
#include <gtest/internal/gtest-param-util-generated.h>
#ifdef GTEST_HAS_COMBINE
#include <tr1/tuple>
#endif // GTEST_HAS_COMBINE
namespace
testing
{
namespace
testing
{
...
...
include/gtest/internal/gtest-param-util-generated.h
View file @
5145e0fb
...
@@ -48,10 +48,6 @@
...
@@ -48,10 +48,6 @@
#ifdef GTEST_HAS_PARAM_TEST
#ifdef GTEST_HAS_PARAM_TEST
#ifdef GTEST_HAS_COMBINE
#include <tr1/tuple>
#endif // GTEST_HAS_COMBINE
#include <gtest/internal/gtest-param-util.h>
#include <gtest/internal/gtest-param-util.h>
namespace
testing
{
namespace
testing
{
...
...
include/gtest/internal/gtest-param-util-generated.h.pump
View file @
5145e0fb
...
@@ -49,10 +49,6 @@ $var maxtuple = 10 $$ Maximum number of Combine arguments we want to support.
...
@@ -49,10 +49,6 @@ $var maxtuple = 10 $$ Maximum number of Combine arguments we want to support.
#ifdef GTEST_HAS_PARAM_TEST
#ifdef GTEST_HAS_PARAM_TEST
#ifdef GTEST_HAS_COMBINE
#include <tr1/tuple>
#endif // GTEST_HAS_COMBINE
#include <gtest/internal/gtest-param-util.h>
#include <gtest/internal/gtest-param-util.h>
namespace
testing
{
namespace
testing
{
...
...
include/gtest/internal/gtest-port.h
View file @
5145e0fb
...
@@ -301,10 +301,10 @@
...
@@ -301,10 +301,10 @@
#endif // GTEST_HAS_PTHREAD
#endif // GTEST_HAS_PTHREAD
// Determines whether
<
tr1/tuple
>
is available. If you have
<
tr1/tuple
>
// Determines whether tr1/tuple is available. If you have tr1/tuple
// on your platform, define GTEST_HAS_TR1_TUPLE=1 for both the Google
// on your platform, define GTEST_HAS_TR1_TUPLE=1 for both the Google
// Test project and your tests. If you would like Google Test to detect
// Test project and your tests. If you would like Google Test to detect
//
<
tr1/tuple
>
on your platform automatically, please open an issue
// tr1/tuple on your platform automatically, please open an issue
// ticket at http://code.google.com/p/googletest.
// ticket at http://code.google.com/p/googletest.
#ifndef GTEST_HAS_TR1_TUPLE
#ifndef GTEST_HAS_TR1_TUPLE
// The user didn't tell us, so we need to figure it out.
// The user didn't tell us, so we need to figure it out.
...
@@ -317,6 +317,21 @@
...
@@ -317,6 +317,21 @@
#endif // __GNUC__
#endif // __GNUC__
#endif // GTEST_HAS_TR1_TUPLE
#endif // GTEST_HAS_TR1_TUPLE
// To avoid conditional compilation everywhere, we make it
// gtest-port.h's responsibility to #include the header implementing
// tr1/tuple.
#if GTEST_HAS_TR1_TUPLE
#if defined(__GNUC__)
// GCC implements tr1/tuple in the <tr1/tuple> header. This does not
// conform to the TR1 spec, which requires the header to be <tuple>.
#include <tr1/tuple>
#else
// If the compiler is not GCC, we assume the user is using a
// spec-conforming TR1 implementation.
#include <tuple>
#endif // __GNUC__
#endif // GTEST_HAS_TR1_TUPLE
// Determines whether clone(2) is supported.
// Determines whether clone(2) is supported.
// Usually it will only be available on Linux, excluding
// Usually it will only be available on Linux, excluding
// Linux on the Itanium architecture.
// Linux on the Itanium architecture.
...
...
test/gtest-param-test_test.cc
View file @
5145e0fb
...
@@ -42,10 +42,6 @@
...
@@ -42,10 +42,6 @@
#include <list>
#include <list>
#include <vector>
#include <vector>
#ifdef GTEST_HAS_COMBINE
#include <tr1/tuple>
#endif // GTEST_HAS_COMBINE
// To include gtest-internal-inl.h.
// To include gtest-internal-inl.h.
#define GTEST_IMPLEMENTATION
#define GTEST_IMPLEMENTATION
#include "src/gtest-internal-inl.h" // for UnitTestOptions
#include "src/gtest-internal-inl.h" // for UnitTestOptions
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment