Progmasoft Git

catch3

Progmasoft Catch3: an independently maintained C++17 test framework with a parallel runner, property checks, snapshots and structured results.

Clonegit clone https://git.progmasoft.com/catch3

Combined matchers are now final

Commit
260263b9bfe8bdeaf45d40a0a3dead26149f5d0f
Author
Martin Hořeňovský ·
Parents
cf6575576f1c

Files · Download .tar.gz

Changes

 src/catch2/catch_matchers.h             | 6 +++---
 src/catch2/catch_matchers_templates.hpp | 6 +++---
 2 files changed, 6 insertions(+), 6 deletions(-)

diff --git a/src/catch2/catch_matchers.h b/src/catch2/catch_matchers.h
index 78f12da9..2d43cb8a 100644
--- a/src/catch2/catch_matchers.h
+++ b/src/catch2/catch_matchers.h
@@ -58,7 +58,7 @@ namespace Matchers {
     namespace Detail {
 
         template<typename ArgT>
-        struct MatchAllOf : MatcherBase<ArgT> {
+        struct MatchAllOf final : MatcherBase<ArgT> {
             MatchAllOf() = default;
             MatchAllOf(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;
 
         template<typename ArgT>
-        struct MatchAnyOf : MatcherBase<ArgT> {
+        struct MatchAnyOf final : MatcherBase<ArgT> {
             MatchAnyOf() = default;
             MatchAnyOf(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;
 
         template<typename ArgT>
-        struct MatchNotOf : MatcherBase<ArgT> {
+        struct MatchNotOf final : MatcherBase<ArgT> {
 
             explicit MatchNotOf( MatcherBase<ArgT> const& underlyingMatcher ):
                 m_underlyingMatcher( underlyingMatcher )
diff --git a/src/catch2/catch_matchers_templates.hpp b/src/catch2/catch_matchers_templates.hpp
index d770f25c..43efc5b0 100644
--- a/src/catch2/catch_matchers_templates.hpp
+++ b/src/catch2/catch_matchers_templates.hpp
@@ -107,7 +107,7 @@ namespace Matchers {
 
 
         template<typename... MatcherTs>
-        struct MatchAllOfGeneric : MatcherGenericBase {
+        struct MatchAllOfGeneric final : MatcherGenericBase {
             MatchAllOfGeneric(MatcherTs const&... matchers) : m_matchers{std::addressof(matchers)...} {}
             explicit MatchAllOfGeneric(std::array<void const*, sizeof...(MatcherTs)> matchers) : m_matchers{matchers} {}
 
@@ -125,7 +125,7 @@ namespace Matchers {
 
 
         template<typename... MatcherTs>
-        struct MatchAnyOfGeneric : MatcherGenericBase {
+        struct MatchAnyOfGeneric final : MatcherGenericBase {
             MatchAnyOfGeneric(MatcherTs const&... matchers) : m_matchers{std::addressof(matchers)...} {}
             explicit MatchAnyOfGeneric(std::array<void const*, sizeof...(MatcherTs)> matchers) : m_matchers{matchers} {}
 
@@ -143,7 +143,7 @@ namespace Matchers {
 
 
         template<typename MatcherT>
-        struct MatchNotOfGeneric : MatcherGenericBase {
+        struct MatchNotOfGeneric final : MatcherGenericBase {
             explicit MatchNotOfGeneric(MatcherT const& matcher) : m_matcher{matcher} {}
 
             template<typename Arg>