aboutsummaryrefslogtreecommitdiffstats
path: root/googlemock/include/gmock/internal
diff options
context:
space:
mode:
authorAbseil Team <absl-team@google.com>2020-04-24 05:17:47 -0400
committerGennadiy Rozental <rogeeff@google.com>2020-05-01 17:11:34 -0400
commit955552518b4e0ad0249396e6885c0f18cd4ce529 (patch)
tree9a79bd65f70772fbbef632874d7ef233dd41ea4d /googlemock/include/gmock/internal
parentd7ca9af0049e5f33dbfcf0356ba5ee0c04579054 (diff)
downloadgoogletest-955552518b4e0ad0249396e6885c0f18cd4ce529.tar.gz
googletest-955552518b4e0ad0249396e6885c0f18cd4ce529.tar.bz2
googletest-955552518b4e0ad0249396e6885c0f18cd4ce529.zip
Googletest export
Rewrite ReturnNew action without using pump. PiperOrigin-RevId: 308219616
Diffstat (limited to 'googlemock/include/gmock/internal')
-rw-r--r--googlemock/include/gmock/internal/gmock-internal-utils.h10
1 files changed, 6 insertions, 4 deletions
diff --git a/googlemock/include/gmock/internal/gmock-internal-utils.h b/googlemock/include/gmock/internal/gmock-internal-utils.h
index 66cf857b..5580dcb3 100644
--- a/googlemock/include/gmock/internal/gmock-internal-utils.h
+++ b/googlemock/include/gmock/internal/gmock-internal-utils.h
@@ -422,11 +422,13 @@ auto ApplyImpl(F&& f, Tuple&& args, IndexSequence<Idx...>) -> decltype(
// Apply the function to a tuple of arguments.
template <typename F, typename Tuple>
-auto Apply(F&& f, Tuple&& args)
- -> decltype(ApplyImpl(std::forward<F>(f), std::forward<Tuple>(args),
- MakeIndexSequence<std::tuple_size<Tuple>::value>())) {
+auto Apply(F&& f, Tuple&& args) -> decltype(
+ ApplyImpl(std::forward<F>(f), std::forward<Tuple>(args),
+ MakeIndexSequence<std::tuple_size<
+ typename std::remove_reference<Tuple>::type>::value>())) {
return ApplyImpl(std::forward<F>(f), std::forward<Tuple>(args),
- MakeIndexSequence<std::tuple_size<Tuple>::value>());
+ MakeIndexSequence<std::tuple_size<
+ typename std::remove_reference<Tuple>::type>::value>());
}
// Template struct Function<F>, where F must be a function type, contains