Skip to content

Commit

Permalink
Merge pull request #2815 from Quuxplusone:simple
Browse files Browse the repository at this point in the history
PiperOrigin-RevId: 308625388
  • Loading branch information
rogeeff committed May 1, 2020
2 parents 9555525 + 1b066f4 commit ef25d27
Show file tree
Hide file tree
Showing 13 changed files with 21 additions and 176 deletions.
8 changes: 4 additions & 4 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,16 +25,16 @@ matrix:
script: ./ci/build-linux-bazel.sh
- os: linux
compiler: gcc
env: BUILD_TYPE=Debug VERBOSE=1 CXX_FLAGS=-std=c++11
env: BUILD_TYPE=Debug VERBOSE=1 CXX_FLAGS="-std=c++11 -Wdeprecated"
- os: linux
compiler: clang
env: BUILD_TYPE=Release VERBOSE=1 CXX_FLAGS=-std=c++11 NO_EXCEPTION=ON NO_RTTI=ON COMPILER_IS_GNUCXX=ON
env: BUILD_TYPE=Release VERBOSE=1 CXX_FLAGS="-std=c++11 -Wdeprecated" NO_EXCEPTION=ON NO_RTTI=ON COMPILER_IS_GNUCXX=ON
- os: osx
compiler: gcc
env: BUILD_TYPE=Release VERBOSE=1 CXX_FLAGS=-std=c++11 HOMEBREW_LOGS=~/homebrew-logs HOMEBREW_TEMP=~/homebrew-temp
env: BUILD_TYPE=Release VERBOSE=1 CXX_FLAGS="-std=c++11 -Wdeprecated" HOMEBREW_LOGS=~/homebrew-logs HOMEBREW_TEMP=~/homebrew-temp
- os: osx
compiler: clang
env: BUILD_TYPE=Release VERBOSE=1 CXX_FLAGS=-std=c++11 HOMEBREW_LOGS=~/homebrew-logs HOMEBREW_TEMP=~/homebrew-temp
env: BUILD_TYPE=Release VERBOSE=1 CXX_FLAGS="-std=c++11 -Wdeprecated" HOMEBREW_LOGS=~/homebrew-logs HOMEBREW_TEMP=~/homebrew-temp

# These are the install and build (script) phases for the most common entries in the matrix. They could be included
# in each entry in the matrix, but that is just repetitive.
Expand Down
36 changes: 0 additions & 36 deletions googlemock/include/gmock/gmock-actions.h
Original file line number Diff line number Diff line change
Expand Up @@ -571,13 +571,9 @@ class PolymorphicAction {

private:
Impl impl_;

GTEST_DISALLOW_ASSIGN_(MonomorphicImpl);
};

Impl impl_;

GTEST_DISALLOW_ASSIGN_(PolymorphicAction);
};

// Creates an Action from its implementation and returns it. The
Expand Down Expand Up @@ -718,13 +714,9 @@ class ReturnAction {
private:
bool performed_;
const std::shared_ptr<R> wrapper_;

GTEST_DISALLOW_ASSIGN_(Impl);
};

const std::shared_ptr<R> value_;

GTEST_DISALLOW_ASSIGN_(ReturnAction);
};

// Implements the ReturnNull() action.
Expand Down Expand Up @@ -785,13 +777,9 @@ class ReturnRefAction {

private:
T& ref_;

GTEST_DISALLOW_ASSIGN_(Impl);
};

T& ref_;

GTEST_DISALLOW_ASSIGN_(ReturnRefAction);
};

// Implements the polymorphic ReturnRefOfCopy(x) action, which can be
Expand Down Expand Up @@ -832,13 +820,9 @@ class ReturnRefOfCopyAction {

private:
T value_;

GTEST_DISALLOW_ASSIGN_(Impl);
};

const T value_;

GTEST_DISALLOW_ASSIGN_(ReturnRefOfCopyAction);
};

// Implements the polymorphic ReturnRoundRobin(v) action, which can be
Expand Down Expand Up @@ -895,8 +879,6 @@ class AssignAction {
private:
T1* const ptr_;
const T2 value_;

GTEST_DISALLOW_ASSIGN_(AssignAction);
};

#if !GTEST_OS_WINDOWS_MOBILE
Expand All @@ -918,8 +900,6 @@ class SetErrnoAndReturnAction {
private:
const int errno_;
const T result_;

GTEST_DISALLOW_ASSIGN_(SetErrnoAndReturnAction);
};

#endif // !GTEST_OS_WINDOWS_MOBILE
Expand Down Expand Up @@ -1025,13 +1005,9 @@ class IgnoreResultAction {
OriginalFunction;

const Action<OriginalFunction> action_;

GTEST_DISALLOW_ASSIGN_(Impl);
};

const A action_;

GTEST_DISALLOW_ASSIGN_(IgnoreResultAction);
};

template <typename InnerAction, size_t... I>
Expand Down Expand Up @@ -1493,13 +1469,7 @@ auto InvokeArgumentAdl(AdlTag, F f, Args... args) -> decltype(f(args...)) {
template <GMOCK_ACTION_TEMPLATE_ARGS_NAMES_> \
return_type gmock_PerformImpl(GMOCK_ACTION_ARG_TYPES_AND_NAMES_) const; \
GMOCK_ACTION_FIELD_PARAMS_(params) \
\
private: \
GTEST_DISALLOW_ASSIGN_(gmock_Impl); \
}; \
\
private: \
GTEST_DISALLOW_ASSIGN_(full_name); \
}; \
template <GMOCK_ACTION_TYPENAME_PARAMS_(params)> \
inline full_name<GMOCK_ACTION_TYPE_PARAMS_(params)> name( \
Expand Down Expand Up @@ -1538,13 +1508,7 @@ auto InvokeArgumentAdl(AdlTag, F f, Args... args) -> decltype(f(args...)) {
} \
template <GMOCK_ACTION_TEMPLATE_ARGS_NAMES_> \
return_type gmock_PerformImpl(GMOCK_ACTION_ARG_TYPES_AND_NAMES_) const; \
\
private: \
GTEST_DISALLOW_ASSIGN_(gmock_Impl); \
}; \
\
private: \
GTEST_DISALLOW_ASSIGN_(name##Action); \
}; \
inline name##Action name() { return name##Action(); } \
template <typename F> \
Expand Down
4 changes: 0 additions & 4 deletions googlemock/include/gmock/gmock-generated-actions.h
Original file line number Diff line number Diff line change
Expand Up @@ -435,16 +435,12 @@
template <GMOCK_ACTION_TEMPLATE_ARGS_NAMES_>\
return_type gmock_PerformImpl(GMOCK_ACTION_ARG_TYPES_AND_NAMES_) const;\
GMOCK_INTERNAL_DEFN_##value_params\
private:\
GTEST_DISALLOW_ASSIGN_(gmock_Impl);\
};\
template <typename F> operator ::testing::Action<F>() const {\
return ::testing::Action<F>(\
new gmock_Impl<F>(GMOCK_INTERNAL_LIST_##value_params));\
}\
GMOCK_INTERNAL_DEFN_##value_params\
private:\
GTEST_DISALLOW_ASSIGN_(GMOCK_ACTION_CLASS_(name, value_params));\
};\
template <GMOCK_INTERNAL_DECL_##template_params\
GMOCK_INTERNAL_DECL_TYPE_##value_params>\
Expand Down
4 changes: 0 additions & 4 deletions googlemock/include/gmock/gmock-generated-actions.h.pump
Original file line number Diff line number Diff line change
Expand Up @@ -253,16 +253,12 @@ $range k 0..n-1
template <GMOCK_ACTION_TEMPLATE_ARGS_NAMES_>\
return_type gmock_PerformImpl(GMOCK_ACTION_ARG_TYPES_AND_NAMES_) const;\
GMOCK_INTERNAL_DEFN_##value_params\
private:\
GTEST_DISALLOW_ASSIGN_(gmock_Impl);\
};\
template <typename F> operator ::testing::Action<F>() const {\
return ::testing::Action<F>(\
new gmock_Impl<F>(GMOCK_INTERNAL_LIST_##value_params));\
}\
GMOCK_INTERNAL_DEFN_##value_params\
private:\
GTEST_DISALLOW_ASSIGN_(GMOCK_ACTION_CLASS_(name, value_params));\
};\
template <GMOCK_INTERNAL_DECL_##template_params\
GMOCK_INTERNAL_DECL_TYPE_##value_params>\
Expand Down
Loading

0 comments on commit ef25d27

Please sign in to comment.