SeqAn3  3.2.0-rc.1
The Modern C++ library for sequence analysis.
alphabet/detail/concept.hpp
Go to the documentation of this file.
1 // -----------------------------------------------------------------------------------------------------
2 // Copyright (c) 2006-2022, Knut Reinert & Freie Universität Berlin
3 // Copyright (c) 2016-2022, Knut Reinert & MPI für molekulare Genetik
4 // This file may be used, modified and/or redistributed under the terms of the 3-clause BSD-License
5 // shipped with this file and also available at: https://github.com/seqan/seqan3/blob/master/LICENSE.md
6 // -----------------------------------------------------------------------------------------------------
7 
13 #pragma once
14 
15 #include <concepts>
16 
17 #include <seqan3/core/platform.hpp>
18 
19 namespace seqan3::detail
20 {
28 template <class T, class U>
29 concept weakly_equality_comparable_with =
31  requires std::convertible_to<decltype(t == u), bool>;
32  requires std::convertible_to<decltype(t != u), bool>;
33  requires std::convertible_to<decltype(u == t), bool>;
34  requires std::convertible_to<decltype(u != t), bool>;
35  };
37 
45 template <typename t1, typename t2>
46 concept weakly_ordered_with =
48  requires std::convertible_to<decltype(v1 < v2), bool>;
49  requires std::convertible_to<decltype(v1 <= v2), bool>;
50  requires std::convertible_to<decltype(v1 > v2), bool>;
51  requires std::convertible_to<decltype(v1 >= v2), bool>;
52 
53  requires std::convertible_to<decltype(v2 < v1), bool>;
54  requires std::convertible_to<decltype(v2 <= v1), bool>;
55  requires std::convertible_to<decltype(v2 > v1), bool>;
56  requires std::convertible_to<decltype(v2 >= v1), bool>;
57  };
59 
60 } // namespace seqan3::detail
The <concepts> header from C++20's standard library.
requires requires
The rank_type of the semi-alphabet; defined as the return type of seqan3::to_rank....
Definition: alphabet/concept.hpp:164
Provides platform and dependency checks.