Mark the default constructor of Matcher<> explicit.
This prevents implicitly constructing a matcher from {}.
This commit is contained in:
parent
9b1a944ec4
commit
d86a723ed9
@ -321,7 +321,7 @@ class Matcher : public internal::MatcherBase<T> {
|
||||
// Constructs a null matcher. Needed for storing Matcher objects in STL
|
||||
// containers. A default-constructed matcher is not yet initialized. You
|
||||
// cannot use it until a valid value has been assigned to it.
|
||||
Matcher() {}
|
||||
explicit Matcher() {} // NOLINT
|
||||
|
||||
// Constructs a matcher from its implementation.
|
||||
explicit Matcher(const MatcherInterface<T>* impl)
|
||||
|
Loading…
Reference in New Issue
Block a user