Combined matchers are now final

This commit is contained in:
Martin Hořeňovský 2020-02-19 18:59:51 +01:00
parent cf6575576f
commit 260263b9bf
No known key found for this signature in database
GPG Key ID: DE48307B8B0D381A
2 changed files with 6 additions and 6 deletions

View File

@ -58,7 +58,7 @@ namespace Matchers {
namespace Detail { namespace Detail {
template<typename ArgT> template<typename ArgT>
struct MatchAllOf : MatcherBase<ArgT> { struct MatchAllOf final : MatcherBase<ArgT> {
MatchAllOf() = default; MatchAllOf() = default;
MatchAllOf(MatchAllOf const&) = delete; MatchAllOf(MatchAllOf const&) = delete;
MatchAllOf& operator=(MatchAllOf const&) = delete; MatchAllOf& operator=(MatchAllOf const&) = delete;
@ -112,7 +112,7 @@ namespace Matchers {
MatchAllOf<ArgT> operator&& (MatcherBase<ArgT> const& lhs, MatchAllOf<ArgT> const& rhs) = delete; MatchAllOf<ArgT> operator&& (MatcherBase<ArgT> const& lhs, MatchAllOf<ArgT> const& rhs) = delete;
template<typename ArgT> template<typename ArgT>
struct MatchAnyOf : MatcherBase<ArgT> { struct MatchAnyOf final : MatcherBase<ArgT> {
MatchAnyOf() = default; MatchAnyOf() = default;
MatchAnyOf(MatchAnyOf const&) = delete; MatchAnyOf(MatchAnyOf const&) = delete;
MatchAnyOf& operator=(MatchAnyOf const&) = delete; MatchAnyOf& operator=(MatchAnyOf const&) = delete;
@ -165,7 +165,7 @@ namespace Matchers {
MatchAnyOf<ArgT> operator|| (MatcherBase<ArgT> const& lhs, MatchAnyOf<ArgT> const& rhs) = delete; MatchAnyOf<ArgT> operator|| (MatcherBase<ArgT> const& lhs, MatchAnyOf<ArgT> const& rhs) = delete;
template<typename ArgT> template<typename ArgT>
struct MatchNotOf : MatcherBase<ArgT> { struct MatchNotOf final : MatcherBase<ArgT> {
explicit MatchNotOf( MatcherBase<ArgT> const& underlyingMatcher ): explicit MatchNotOf( MatcherBase<ArgT> const& underlyingMatcher ):
m_underlyingMatcher( underlyingMatcher ) m_underlyingMatcher( underlyingMatcher )

View File

@ -107,7 +107,7 @@ namespace Matchers {
template<typename... MatcherTs> template<typename... MatcherTs>
struct MatchAllOfGeneric : MatcherGenericBase { struct MatchAllOfGeneric final : MatcherGenericBase {
MatchAllOfGeneric(MatcherTs const&... matchers) : m_matchers{std::addressof(matchers)...} {} MatchAllOfGeneric(MatcherTs const&... matchers) : m_matchers{std::addressof(matchers)...} {}
explicit MatchAllOfGeneric(std::array<void const*, sizeof...(MatcherTs)> matchers) : m_matchers{matchers} {} explicit MatchAllOfGeneric(std::array<void const*, sizeof...(MatcherTs)> matchers) : m_matchers{matchers} {}
@ -125,7 +125,7 @@ namespace Matchers {
template<typename... MatcherTs> template<typename... MatcherTs>
struct MatchAnyOfGeneric : MatcherGenericBase { struct MatchAnyOfGeneric final : MatcherGenericBase {
MatchAnyOfGeneric(MatcherTs const&... matchers) : m_matchers{std::addressof(matchers)...} {} MatchAnyOfGeneric(MatcherTs const&... matchers) : m_matchers{std::addressof(matchers)...} {}
explicit MatchAnyOfGeneric(std::array<void const*, sizeof...(MatcherTs)> matchers) : m_matchers{matchers} {} explicit MatchAnyOfGeneric(std::array<void const*, sizeof...(MatcherTs)> matchers) : m_matchers{matchers} {}
@ -143,7 +143,7 @@ namespace Matchers {
template<typename MatcherT> template<typename MatcherT>
struct MatchNotOfGeneric : MatcherGenericBase { struct MatchNotOfGeneric final : MatcherGenericBase {
explicit MatchNotOfGeneric(MatcherT const& matcher) : m_matcher{matcher} {} explicit MatchNotOfGeneric(MatcherT const& matcher) : m_matcher{matcher} {}
template<typename Arg> template<typename Arg>