Commit Graph

317 Commits

Author SHA1 Message Date
Vladimir Goncharov
9ac4cd0f49 Add matchers for testing exception properties
This PR adds matchers that accept a callable and verify that when invoked, it throws an exception with the given type and properties.

Fixes #952
2020-08-03 23:47:57 +03:00
ofats
c64309924d Googletest export
Stop using ADL for InvokeArgument action.

PiperOrigin-RevId: 323234396
2020-07-28 14:21:59 -04:00
Abseil Team
356f2d264a Googletest export
Improve compatibility with strict compilers targeting Windows

Remove an unnecessary ##, which could result in warnings about invalid preprocessor tokens when pasting to an initial '('

PiperOrigin-RevId: 319277617
2020-07-05 16:25:43 -04:00
Abseil Team
13a433a94d Googletest export
Change string matchers, like HasSubstr, to accept `string_view` input if available.

PiperOrigin-RevId: 315726484
2020-06-10 17:37:39 -04:00
dmauro
8f3854e204 Googletest export
Rollback of warning on unused ACTION result change

PiperOrigin-RevId: 313380971
2020-05-28 19:54:56 -04:00
Abseil Team
1397db9e58 Googletest export
Mark ACTION_Pn()-generated functions as must-use-result.

This catches when a client creates an action and discards it, thinking that the action has actually been applied to something.

This will help people who make the mistake of defining, for example, both `void Use(Foo*)` and `ACTION(Use) { Use(arg); }` for later application to a Foo.  With such an overload, a client may then write `Use();`, forgetting the param and being confused why nothing happens.

This also catches when a client defines their own action in terms of an ACTION()-generated one, invokes the ACTION's builder, and then fails to invoke the resulting action, thinking it's operating on the outer action's parameters.

PiperOrigin-RevId: 312108101
2020-05-28 19:53:34 -04:00
Abseil Team
63713e1ce4 Googletest export
Fix the ACTION* macros to allow for more than 10 arguments in the action.
Only the first 10 will be passed as individual arguments as `argN`, but the rest
can be accessed from the `args` tuple.

PiperOrigin-RevId: 311542098
2020-05-28 19:53:26 -04:00
Abseil Team
a09ea700d3 Googletest export
Fix `-Wgnu-zero-variadic-macro-arguments` in GMock

Passing zero arguments to the variadic part of a macro is a GNU
extension and triggers warnings when build projects using GMock with
`-pedantic`.

 - Fix uses of `GMOCK_PP_INTERNAL_16TH` to always receive at least 17
arguments. (this was triggered when `GMOCK_PP_NARG` or `GMOCK_PP_HAS_COMMA`
were used with an argument containing no commas).
 - Fix `GMOCK_PP_HEAD` to append a dummy unused argument so that
`GMOCK_PP_INTERNAL_HEAD` always has two arguments.

PiperOrigin-RevId: 310414611
2020-05-07 16:15:58 -04:00
Gennadiy Rozental
ef25d27d46 Merge pull request #2815 from Quuxplusone:simple
PiperOrigin-RevId: 308625388
2020-05-01 17:11:43 -04:00
Abseil Team
955552518b Googletest export
Rewrite ReturnNew action without using pump.

PiperOrigin-RevId: 308219616
2020-05-01 17:11:34 -04:00
Abseil Team
fb5d9b66c5 Googletest export
Fix comment that describes how to test against nullopt.

PiperOrigin-RevId: 307448375
2020-05-01 17:11:00 -04:00
Arthur O'Dwyer
11b3cec177 Fix a -Wdeprecated warning.
gmock-spec-builders.h:503:3: error:
    definition of implicit copy constructor for 'Expectation' is deprecated
    because it has a user-declared destructor [-Werror,-Wdeprecated]
        ~Expectation();
        ^
2020-04-23 22:22:34 -04:00
Arthur O'Dwyer
766ac2e1a4 Remove all uses of GTEST_DISALLOW_{MOVE_,}ASSIGN_.
None of these are strictly needed for correctness.
A large number of them (maybe all of them?) trigger `-Wdeprecated`
warnings on Clang trunk as soon as you try to use the implicitly
defaulted (but deprecated) copy constructor of a class that has
deleted its copy assignment operator.

By declaring a deleted copy assignment operator, the old code
also caused the move constructor and move assignment operator
to be non-declared. This means that the old code never got move
semantics -- "move-construction" would simply call the defaulted
(but deprecated) copy constructor instead. With the new code,
"move-construction" calls the defaulted move constructor, which
I believe is what we want to happen. So this is a runtime
performance optimization.

Unfortunately we can't yet physically remove the definitions
of these macros from gtest-port.h, because they are being used
by other code internally at Google (according to zhangxy988).
But no new uses should be added going forward.
2020-04-23 22:22:07 -04:00
Arthur O'Dwyer
4f002f1e23 VariadicMatcher needs a non-defaulted move constructor for compile-time performance.
We are about to remove all uses of GTEST_DISALLOW_ASSIGN_ in favor
of using the Rule of Zero everywhere.

Unfortunately, if we use the Rule of Zero here, then when the compiler
needs to figure out if VariadicMatcher is move-constructible, it will
recurse down into `tuple<Args...>`, which on libstdc++ recurses too deeply.

    In file included from googlemock/test/gmock-matchers_test.cc:43:
    In file included from googlemock/include/gmock/gmock-matchers.h:258:
    In file included from /usr/include/c++/5.5.0/algorithm:60:
    In file included from /usr/include/c++/5.5.0/utility:70:
    In file included from /usr/include/c++/5.5.0/bits/stl_pair.h:59:
    In file included from /usr/include/c++/5.5.0/bits/move.h:57:
    /usr/bin/include/c++/5.5.0/type_traits:115:26: fatal error:
          recursive template instantiation exceeded maximum depth of 256
        : public conditional<_B1::value, _B1, _B2>::type
                             ^

The move constructor is the only problematic case, for some unknown reason.
With GTEST_DISALLOW_ASSIGN_, the presence of a copy assignment operator
causes the move constructor to be non-declared, thus non-defaulted, thus
non-problematic. Without GTEST_DISALLOW_ASSIGN_, we have to do one of the
following:

- Default the copy constructor, so that the move constructor will be non-declared.

- Define our own non-defaulted move constructor.

...except that doing the latter STILL did not work!
Fortunately, the former (default the copy constructor, don't provide
any move constructor) both works in practice and is semantically
equivalent to the old code.
2020-04-16 19:12:52 -04:00
Abseil Team
61f010d703 Googletest export
Do not use std::result_of as it was removed in C++20.

PiperOrigin-RevId: 303783600
2020-03-31 19:23:38 -04:00
Xiaoyi Zhang
67cc66080d Merge pull request #2350 from adambadura:MockFunctionFromStdFunction
PiperOrigin-RevId: 302677275
2020-03-24 17:32:16 -04:00
Adam Badura
53740ebc21 Add support for std::function in MockFunction (#2277) 2020-03-18 01:11:30 +01:00
Abseil Team
909b1ccfca Googletest export
Relax the implementation of MatcherCast to allow conversion of `Matcher<T>` to
`Matcher<const T&>`. They have the same match signature.

PiperOrigin-RevId: 297115843
2020-02-28 16:41:01 -05:00
Abseil Team
fd538161f4 Googletest export
Allow construction of an Action from a callable of zero args

Action already allows construction from a callable with the same args as the mocked function, without needing to wrap the callable in Invoke. However, if you don't care about the arguments to the mocked function you need to either accept all of them or wrap your callable in InvokeWithoutArgs. This change makes both of those unnecessary, since it allows you to pass a no-args callable to Action directly.

PiperOrigin-RevId: 296117034
2020-02-28 16:40:53 -05:00
Abseil Team
6f5fd0d719 Googletest export
Add gmock Matcher<std::string_view> specialization.

PiperOrigin-RevId: 294443240
2020-02-11 15:50:26 -05:00
Abseil Team
41b5f149ab Googletest export
Get rid of gmock-generated-matchers.h and gmock-generated-matchers.h.pump.

Stop using pump for MATCHER* macroses generation.

PiperOrigin-RevId: 293878808
2020-02-07 18:20:45 -05:00
durandal
2d6d7a01c9 Googletest export
Tag the function generated by MATCHER with GTEST_ATTRIBUTE_UNUSED_ to fix CI builds of gmock-matchers_test.cc vs. -Wunused-function.

See https://github.com/google/googletest/pull/2697 for breakage.

PiperOrigin-RevId: 293669752
2020-02-07 13:35:36 -05:00
Abseil Team
fbf67a70d0 Googletest export
Get rid of gmock-generated-function-mockers.h and
gmock-generated-function-mockers.h.pump.

Stop using pump for GMOCK_METHOD* macroses generation.

PiperOrigin-RevId: 293454519
2020-02-07 13:35:27 -05:00
Abseil Team
d02e277275 Googletest export
Pass method's parameters count to internal GMOCK_METHOD* macro.

This will help removing copypaste in every GMOCK_METHOD* macro in future.

PiperOrigin-RevId: 292932554
2020-02-07 13:35:10 -05:00
Abseil Team
4f6609129a Googletest export
Fix std::move to std::forward where appropriate to support reference types.

PiperOrigin-RevId: 292923058
2020-02-07 13:35:00 -05:00
Abseil Team
572e261b60 Googletest export
Fix use of reserved names.
Minimize code duplication needed for explict-vs-nonexplicit constructor.

PiperOrigin-RevId: 292555014
2020-02-07 13:34:42 -05:00
Abseil Team
38f6608e87 Googletest export
Add includes for type_traits and utility to gmock-function-mocker.h: macros in the file require these headers.

PiperOrigin-RevId: 291782497
2020-02-07 13:34:26 -05:00
Abseil Team
d6ce39edf6 Googletest export
Create implementation macroses for matchers to move variadic parameters to the
end of parameters list.

To save backward compatibility, old macroses will be still taking `description`
parameter as the last one. But they will use INTERNAL macro that takes
`description` as the second parameter.

PiperOrigin-RevId: 291724469
2020-02-07 13:34:18 -05:00
Abseil Team
87061810f4 Googletest export
Move part of functionality of Matcher* class to the base one. Reduce copypaste.

Make constructor and conversion operator of Matcher* class independent of pump.

PiperOrigin-RevId: 291405510
2020-02-07 13:34:03 -05:00
Abseil Team
22397f28ef Googletest export
Add missing explicit keyword for gmock_Impl constructor.

When switching to using GMOCK_PP in ACTION* macroses `explicit` keyword was
missed in gmock_Impl constructor causing ClangTidy warnings in ACTION_P macro.

PiperOrigin-RevId: 291159975
2020-02-07 13:33:47 -05:00
Abseil Team
d01e356e15 Googletest export
Allow copying of the string in MatchAndExplain.

Otherwise, conversions from std::string_view to std::string will fail as being
explicit

PiperOrigin-RevId: 290301103
2020-01-21 16:26:33 -05:00
Abseil Team
5336106b66 Googletest export
Use GMOCK_PP to create GMOCK_INTERNAL_ACTION macro.

Create GMOCK_INTERNAL_ACTION macro that generates ACTION_P* macroses using
GMOCK_PP.

PiperOrigin-RevId: 289815906
2020-01-16 13:56:12 -05:00
Abseil Team
7a8591e6e4 Googletest export
Use GMOCK_PP to generate args boilerplate.

Move common args describing part to separate macroses that uses GMOCK_PP to
generate sequences.

PiperOrigin-RevId: 289655624
2020-01-16 13:55:54 -05:00
Abseil Team
c901f67ddf Googletest export
Move part of functionality of Action* class to the base one. Reduce copypaste.

Make constructor and conversion operator of Action* class independent of pump.

PiperOrigin-RevId: 288907005
2020-01-09 18:25:24 -05:00
Abseil Team
4b9c1691c4 Googletest export
Use C++11 variadic templates for Invoke in gmock-generated-actions.h.

Replace InvokeArgumentAdl with Invoke that uses C++11 variadic templates.

PiperOrigin-RevId: 288449236
2020-01-09 18:25:08 -05:00
Abseil Team
306f3754a7 Googletest export
Explicitly default copy constructor in BoundSecondMatcher

Since C++11, implicit defaulting of copy constructors is deprecated for types
with user-defined copy assignment operators, so we should explicitly default the
copy constructor of BoundSecondMatcher.

PiperOrigin-RevId: 287587847
2020-01-02 16:49:38 -05:00
Abseil Team
d0a521255e Googletest export
Use C++11 variadic templates for InvokeArgumentAdl in gmock-generated-actions.h.

Make InvokeArgumentAdl use variadic templates to generate its overloads instead
of using pump.py syntax.

PiperOrigin-RevId: 286267615
2020-01-02 16:48:42 -05:00
Abseil Team
6f1a8ffde9 Googletest export
Use C++11 variadic templates for InvokeArgumentAdl in gmock-generated-actions.h.

Make InvokeArgumentAdl use variadic templates to generate its overloads instead
of using pump.py syntax.

PiperOrigin-RevId: 286148805
2020-01-02 16:48:34 -05:00
Abseil Team
d8eeb9760a Googletest export
Use C++11 variadic templates for ActionHelper in gmock-generated-actions.h.

Make ActionHelper use variadic templates to generate Perform static member function specializations instead of using pump.py syntax.

PiperOrigin-RevId: 284988441
2019-12-13 12:57:53 -05:00
Matt Calabrese
88ba008c23 Merge pull request #2595 from kuzkry:remove-workaround_msvc-warning-4355
PiperOrigin-RevId: 284234675
2019-12-13 12:57:35 -05:00
Mark Barolak
1d563578c8 Merge pull request #2594 from kuzkry:remove-workaround_msvc-unneeded-const-dropping
PiperOrigin-RevId: 283979494
2019-12-05 14:41:50 -05:00
Gennadiy Rozental
b155875f32 Merge pull request #2583 from ChristophStrehle:master
PiperOrigin-RevId: 282817206
2019-11-27 16:20:38 -05:00
Gennadiy Rozental
db13ff1f0b Merge pull request #2597 from kuzkry:remove-workaround_Nokia-Sybian-SafeMatcherCastImpl
PiperOrigin-RevId: 282581402
2019-11-26 15:47:21 -05:00
Abseil Team
717ce7feb8 Googletest export
Use standard C++11 integer types in gtest-port.h.

Remove testing::internal::{Int,Uint}{32,64} in favor of types
guaranteed to be in <cstdint> since C++11.

Tests for built-in integer type coverage are switched from
{Int,Uint}64 to [unsigned] long long, which is guaranteed by
C++11 to exist and be at least 64-bit wide.

PiperOrigin-RevId: 281565263
2019-11-22 16:33:15 -05:00
Krystian Kuzniarek
bbbc5d8a4b remove Nokia's Symbian compiler workaround: SafeMatcherCastImpl 2019-11-22 17:25:34 +01:00
Krystian Kuzniarek
e0c80b0a6e consistency fix for SafeMatcherCastImpl member functions 2019-11-22 17:25:34 +01:00
Krystian Kuzniarek
6748df1eab remove MSVC workaround: cease const dropping 2019-11-22 17:17:41 +01:00
Krystian Kuzniarek
ecefcbd4aa remove MSVC workaround: warning 4355 2019-11-22 17:15:23 +01:00
Christoph Strehle
6a9d6d5c28 Fix compile break for Microsoft Visual Studio 2017 v141
This is a workaround, for those who have to compile with v141 build tools,
for a bug in msvc that the compiler can't compile the WithArgsAction.

see the following link for more details:
https://developercommunityapi.westus.cloudapp.azure.com/content/problem/420339/googlemocks-withargs-doesnt-compile-with-permissiv.html
2019-11-21 14:58:09 +01:00
Abseil Team
50cfbb726b Googletest export
Update stale comments to point to proper location.

PiperOrigin-RevId: 281157036
2019-11-19 11:25:59 -05:00
Krystian Kuzniarek
f658561ef2 fix a typo 2019-11-02 01:18:21 +01:00
vslashg
057ee5063d Merge pull request #2533 from thejcannon:noexcept_spec
PiperOrigin-RevId: 277924721
2019-11-01 16:02:05 -04:00
Abseil Team
2db3df9c4f Googletest export
Change variable name to match comment.

PiperOrigin-RevId: 277713621
2019-10-31 15:11:41 -04:00
Abseil Team
e2fc3a9c9c Googletest export
Tolerate std::string's explicit copy construction from std::string_view.

PiperOrigin-RevId: 277583394
2019-10-31 15:11:31 -04:00
Abseil Team
755f853c6b Googletest export
Avoid temporary matcher instances.
They are unnecessary and can be relatively more expensive than the rest of the
algorithm.

PiperOrigin-RevId: 277084853
2019-10-29 16:51:31 -04:00
vslashg
b5fb5ba05c Merge pull request #2527 from PiotrNycz:gmock_prevent_return_ref_to_store_temporaries_2
PiperOrigin-RevId: 277061341
2019-10-29 16:51:12 -04:00
Abseil Team
37f3227831 Googletest export
Add a matcher `testing::ReturnRoundRobin` which, on each call, returns the next element in the sequence, restarting at the beginning once it has reached the end.

PiperOrigin-RevId: 276312136
2019-10-23 15:54:45 -04:00
Joshua Cannon
676d0444bf Revert "Merge pull request #2498 from thejcannon:noexcept_spec"
This reverts commit ba513d2c95, reversing
changes made to a3ca5b9e0b.
2019-10-23 14:46:46 -05:00
vslashg
8bab7883a6 Merge pull request #2514 from thejcannon:msvc_macro_issue
PiperOrigin-RevId: 276134684
2019-10-23 13:35:26 -04:00
Piotr Nycz
b11fb80e9e Prevent using ReturnRef on reference to temporary
Fixed issue: 2471
2019-10-22 15:58:00 +02:00
Abseil Team
611a321a6e Googletest export
Remove bool_constant in favor of std::integral_constant<bool, ...>;
The one non-trivial use of bool_constant has been changed to have significantly
fewer template specializations.

PiperOrigin-RevId: 275842490
2019-10-22 09:38:12 -04:00
Abseil Team
011c4e23d5 Googletest export
Rolling forward IsNan() matcher with fixes in test for -Wconversion issues. Use
std::nanf and std::nanl where appropriate.
PiperOrigin-RevId: 275523003
2019-10-22 09:37:46 -04:00
misterg
f966ed1581 Googletest export
Added IsNan matcher

PiperOrigin-RevId: 275473218
2019-10-18 11:34:08 -04:00
Abseil Team
1f9edcd969 Googletest export
Addressing https://github.com/google/googletest/issues/2502

Add MOCK_METHOD support for returning function pointers.

PiperOrigin-RevId: 275323671
2019-10-18 11:33:59 -04:00
Abseil Team
bbe4b7363b Googletest export
Added IsNan matcher

PiperOrigin-RevId: 275278634
2019-10-17 13:08:00 -04:00
Joshua Cannon
e1b67b07f7 Avoid recursive macros 2019-10-11 17:13:24 -05:00
Robert Luberda
3cddd56e19 Add more override keywords
Mark more functions with "override" keyword, just like
it was done in commit 2460f97152.

This should prevent compiler from complaining while compiling both
user code, and the googletest code itself with the -Wsuggest-override
option turned on; with the exception of:
 * calls to new MOCK_METHOD() in test/gmock-function-mocker_test.cc
 * calls to old MOCK_METHODx()/MOCK_CONST_METHODx() in other
   unit test files.

Closes #2493
2019-10-11 23:45:31 +02:00
Joshua Cannon
3e813465a4 Removing extraneous parenthesis 2019-10-11 12:37:59 -05:00
Joshua Cannon
f8961b99f4 Evaluate and cat NARG in different macros 2019-10-11 12:13:15 -05:00
Joshua Cannon
d935e8e3ed Fix preprocessor tests 2019-10-11 10:41:47 -05:00
Joshua Cannon
c081ceebfb Workaround MSVC VA_ARGS weirdness 2019-10-11 09:28:25 -05:00
Gennadiy Civil
ba513d2c95 Merge pull request #2498 from thejcannon:noexcept_spec
PiperOrigin-RevId: 274155281
2019-10-11 08:48:11 -04:00
Gennadiy Civil
37905b9d8c Merge pull request #2498 from thejcannon:noexcept_spec
PiperOrigin-RevId: 274097989
2019-10-11 07:07:12 -04:00
Abseil Team
ed78e54f38 Googletest export
Fix the O(n^2) number of instantiations in ElemFromList.
It is now O(n). It still has O(1) instantiation depth.

PiperOrigin-RevId: 273980821
2019-10-11 07:06:56 -04:00
Gennadiy Civil
cb1d5db1a1 Merge pull request #2448 from kuzkry:bad-googletest-export
PiperOrigin-RevId: 273585026
2019-10-10 09:21:38 -04:00
Joshua Cannon
0eadff8a93 Fix spacing 2019-10-07 14:37:39 -05:00
Joshua Cannon
10c1d8c4fa Use the verbatim noexcept spec in MOCKED_METHOD 2019-10-07 14:30:10 -05:00
Abseil Team
cb3f7ce1de Googletest export
Makes testing::ResultOf() work with non-copyable arguments.

PiperOrigin-RevId: 271222632
2019-09-27 16:48:33 -04:00
Krystian Kuzniarek
7c2bd3af98 square away the stuff that hasn't been merged in a manual review
This fixes up ab8f346b (a manual merge) that has abandoned some things
from PR #2395.
2019-09-16 19:21:37 +02:00
kuzkry
f2fb48c3b3 Googletest export
Merge 3bdefdb473d304803d2a38e2a2cd5cdc1827c3bd into fb49e6c164

Closes #2407

COPYBARA_INTEGRATE_REVIEW=https://github.com/google/googletest/pull/2407 from kuzkry:StaticAssertTypeEq 3bdefdb473d304803d2a38e2a2cd5cdc1827c3bd
PiperOrigin-RevId: 269255328
2019-09-16 11:47:35 -04:00
Shaindel Schwartz
c7a03daa99 Merge pull request #2387 from kuzkry:iff
PiperOrigin-RevId: 268693457
2019-09-12 12:10:51 -04:00
Hosein Ghahremanzadeh
ac24edd6e0 Googletest export
Merge 4c9ef099b29d2c840c04643cd9662fd7be712f7b into 565f1b8482

Closes #2403

COPYBARA_INTEGRATE_REVIEW=https://github.com/google/googletest/pull/2403 from IYP-Programer-Yeah:remove-compile-assert-type-equal 4c9ef099b29d2c840c04643cd9662fd7be712f7b
PiperOrigin-RevId: 268681883
2019-09-12 12:10:41 -04:00
kuzkry
ab8f346b07 Googletest export
Merge 7f4f58da20e1066a888d3e4bcbef541db798a605 into 90a443f9c2

Closes #2395

COPYBARA_INTEGRATE_REVIEW=https://github.com/google/googletest/pull/2395 from kuzkry:custom-type-traits-remove_reference 7f4f58da20e1066a888d3e4bcbef541db798a605
PiperOrigin-RevId: 266189044
2019-09-06 08:00:03 -04:00
Gennadiy Civil
d9c55a48ed Merge pull request #2426 from kuzkry:#2396-postreview
PiperOrigin-RevId: 265785837
2019-08-27 21:30:42 -04:00
Gennadiy Civil
fdd6a1dc8c Merge pull request #2382 from kuzkry:dead-metafunction
PiperOrigin-RevId: 265730482
2019-08-27 16:59:59 -04:00
misterg
6a3d632f40 Googletest export
Add tuple version of Optional() matches. This allows Optional() to be used in Pointwise matchers.

PiperOrigin-RevId: 265501882
2019-08-26 14:43:56 -04:00
Krystian Kuzniarek
38ce18e8e6 post-review to db1b7399 (#2396) 2019-08-24 12:08:13 +02:00
Abseil Team
ed2eef6543 Googletest export
Add tuple version of Optional() matches. This allows Optional() to be used in Pointwise matchers.

PiperOrigin-RevId: 265110864
2019-08-23 16:39:21 -04:00
kuzkry
db1b739943 Googletest export
Merge b8ca465e73ac0954a0c9eec2a84bdd8913d5763b into 90a443f9c2

Closes #2396

COPYBARA_INTEGRATE_REVIEW=https://github.com/google/googletest/pull/2396 from kuzkry:custom-type-traits-true/false_type-and-bool_constant b8ca465e73ac0954a0c9eec2a84bdd8913d5763b
PiperOrigin-RevId: 265064856
2019-08-23 16:39:13 -04:00
Xiaoyi Zhang
46525e1e5d Merge pull request #2394 from kuzkry:custom-type-traits-duplication-of-custom-index_sequence
PiperOrigin-RevId: 264863984
2019-08-23 16:39:04 -04:00
Xiaoyi Zhang
fb49e6c164 Merge pull request #2393 from kuzkry:custom-type-traits-remove_const
PiperOrigin-RevId: 264652890
2019-08-21 17:13:34 -04:00
Krystian Kuzniarek
7bd4a7f3e9 restore mistakenly removed iffs in their explicit form
Due to confusion arisen from "iff" standing for "if and only if",
this commit uses the latter.
2019-08-20 12:14:22 +02:00
Gennadiy Civil
d5e9e0c38f Merge pull request #2397 from kuzkry:custom-type-traits-is_reference
PiperOrigin-RevId: 264193098
2019-08-19 14:20:11 -04:00
Krystian Kuzniarek
44de869783 remove a dead metafunction 2019-08-16 07:04:49 +02:00
Abseil Team
d44b137fd1 Googletest export
Remove legacy support for signed wchar_t and unsigned wchar_t.

Clang now errors out on these types as well by default. Rather than making the
condition for these types even more complicated, just remove the tests covering
these types since they don't seem to justify the maintenance burden. We
can reasonably expect these types to work in compilers that support them
without needing specific tests for them since they are treated as standard
integral types.

PiperOrigin-RevId: 263577673
2019-08-15 17:34:34 -04:00
Krystian Kuzniarek
6a015ca1cb reuse IndexSequence from googletest 2019-08-14 14:21:32 +02:00
Krystian Kuzniarek
ec49fbca4c remove custom implementations of std::is_same 2019-08-14 14:00:44 +02:00
Krystian Kuzniarek
da76d01b98 remove a custom implementation of std::is_reference 2019-08-14 13:33:13 +02:00
Krystian Kuzniarek
364839ab14 remove a custom implementation of std::remove_const 2019-08-14 00:34:04 +02:00
CJ Johnson
07ec69a886 Merge pull request #2359 from kuzkry:superfluous-mutable
PiperOrigin-RevId: 261947085
2019-08-06 15:02:42 -04:00