From 31b3f2033d5406cc3e88f28209d523f8ce11381d Mon Sep 17 00:00:00 2001 From: cat Date: Mon, 23 Feb 2026 06:30:37 +0200 Subject: [PATCH] Added Either concept also moved Hashing.hpp to Concept.hpp --- headers/Containers/{Hashing.hpp => Concepts.hpp} | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) rename headers/Containers/{Hashing.hpp => Concepts.hpp} (74%) diff --git a/headers/Containers/Hashing.hpp b/headers/Containers/Concepts.hpp similarity index 74% rename from headers/Containers/Hashing.hpp rename to headers/Containers/Concepts.hpp index c924451..c144e11 100644 --- a/headers/Containers/Hashing.hpp +++ b/headers/Containers/Concepts.hpp @@ -7,8 +7,8 @@ * obtain one at http://mozilla.org/MPL/2.0/. */ -#ifndef GUARD_TOURMALINE_HASHING_H -#define GUARD_TOURMALINE_HASHING_H +#ifndef GUARD_TOURMALINE_CONCEPTS_H +#define GUARD_TOURMALINE_CONCEPTS_H #include #include @@ -17,5 +17,8 @@ template concept Hashable = std::equality_comparable && requires(T x) { { std::hash{}(x) } -> std::convertible_to; }; + +template +concept Either = std::same_as || std::same_as; } // namespace Tourmaline::Containers #endif