Skip to content

Commit 8c387b9

Browse files
committed
Added eq_m
1 parent 3f8f49c commit 8c387b9

File tree

3 files changed

+7
-0
lines changed

3 files changed

+7
-0
lines changed

internals/testing/comparison_test.cpp

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,3 +4,6 @@
44

55
static_assert(
66
lax::value_of_v<lax::gt_m<lax::value_t<int, 2>, lax::value_t<int, 1>>>);
7+
8+
static_assert(
9+
!lax::value_of_v<lax::eq_m<lax::value_t<int, 2>, lax::value_t<int, 1>>>);

provides/include/lax_v1/comparison.hpp

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,9 @@
33
#include "lax_v1/synopsis.hpp"
44
#include "lax_v1/value.hpp"
55

6+
template <class LhsExpr, class RhsExpr>
7+
struct lax_v1::eq_m : auto_t<(value_of_v<LhsExpr> == value_of_v<RhsExpr>)> {};
8+
69
template <class LhsExpr, class RhsExpr>
710
struct lax_v1::gt_m : auto_t<(value_of_v<LhsExpr>> value_of_v<RhsExpr>)> {};
811

provides/include/lax_v1/synopsis.hpp

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,7 @@ template <class Expr> struct neg_m;
3434

3535
// comparison.hpp --------------------------------------------------------------
3636

37+
template <class LhsExpr, class RhsExpr> struct eq_m;
3738
template <class LhsExpr, class RhsExpr> struct gt_m;
3839
template <class LhsExpr, class RhsExpr> struct gte_m;
3940
template <class LhsExpr, class RhsExpr> struct lt_m;

0 commit comments

Comments
 (0)