Read-only mirrors. Development, issues and pull requests are on GitHub.

summaryrefslogtreecommitdiffhomepage
path: root/src
diff options
context:
space:
mode:
authorMartin Hořeňovský2020-05-09 21:07:42 +0200
committerMartin Hořeňovský2020-05-09 21:07:55 +0200
commitb93cf932fb4657ae650f38b5427e01553c7de2e6 (patch)
tree18e121243e32fd4fa7910a0db0458d8d0bc99a2e /src
parenteef6c9b79b43a4f5a902813093266f5a8633eb60 (diff)
downloadcatch3-b93cf932fb4657ae650f38b5427e01553c7de2e6.tar.gz
Use UDLs to construct StringRefs for decomposed operators directly
Diffstat (limited to 'src')
-rw-r--r--src/catch2/internal/catch_decomposer.hpp22
1 files changed, 11 insertions, 11 deletions
diff --git a/src/catch2/internal/catch_decomposer.hpp b/src/catch2/internal/catch_decomposer.hpp
index 260a3f78..6ed828b9 100644
--- a/src/catch2/internal/catch_decomposer.hpp
+++ b/src/catch2/internal/catch_decomposer.hpp
@@ -178,47 +178,47 @@ namespace Catch {
template<typename RhsT>
auto operator == ( RhsT const& rhs ) -> BinaryExpr<LhsT, RhsT const&> const {
- return { compareEqual( m_lhs, rhs ), m_lhs, "==", rhs };
+ return { compareEqual( m_lhs, rhs ), m_lhs, "=="_sr, rhs };
}
auto operator == ( bool rhs ) -> BinaryExpr<LhsT, bool> const {
- return { m_lhs == rhs, m_lhs, "==", rhs };
+ return { m_lhs == rhs, m_lhs, "=="_sr, rhs };
}
template<typename RhsT>
auto operator != ( RhsT const& rhs ) -> BinaryExpr<LhsT, RhsT const&> const {
- return { compareNotEqual( m_lhs, rhs ), m_lhs, "!=", rhs };
+ return { compareNotEqual( m_lhs, rhs ), m_lhs, "!="_sr, rhs };
}
auto operator != ( bool rhs ) -> BinaryExpr<LhsT, bool> const {
- return { m_lhs != rhs, m_lhs, "!=", rhs };
+ return { m_lhs != rhs, m_lhs, "!="_sr, rhs };
}
template<typename RhsT>
auto operator > ( RhsT const& rhs ) -> BinaryExpr<LhsT, RhsT const&> const {
- return { static_cast<bool>(m_lhs > rhs), m_lhs, ">", rhs };
+ return { static_cast<bool>(m_lhs > rhs), m_lhs, ">"_sr, rhs };
}
template<typename RhsT>
auto operator < ( RhsT const& rhs ) -> BinaryExpr<LhsT, RhsT const&> const {
- return { static_cast<bool>(m_lhs < rhs), m_lhs, "<", rhs };
+ return { static_cast<bool>(m_lhs < rhs), m_lhs, "<"_sr, rhs };
}
template<typename RhsT>
auto operator >= ( RhsT const& rhs ) -> BinaryExpr<LhsT, RhsT const&> const {
- return { static_cast<bool>(m_lhs >= rhs), m_lhs, ">=", rhs };
+ return { static_cast<bool>(m_lhs >= rhs), m_lhs, ">="_sr, rhs };
}
template<typename RhsT>
auto operator <= ( RhsT const& rhs ) -> BinaryExpr<LhsT, RhsT const&> const {
- return { static_cast<bool>(m_lhs <= rhs), m_lhs, "<=", rhs };
+ return { static_cast<bool>(m_lhs <= rhs), m_lhs, "<="_sr, rhs };
}
template <typename RhsT>
auto operator | (RhsT const& rhs) -> BinaryExpr<LhsT, RhsT const&> const {
- return { static_cast<bool>(m_lhs | rhs), m_lhs, "|", rhs };
+ return { static_cast<bool>(m_lhs | rhs), m_lhs, "|"_sr, rhs };
}
template <typename RhsT>
auto operator & (RhsT const& rhs) -> BinaryExpr<LhsT, RhsT const&> const {
- return { static_cast<bool>(m_lhs & rhs), m_lhs, "&", rhs };
+ return { static_cast<bool>(m_lhs & rhs), m_lhs, "&"_sr, rhs };
}
template <typename RhsT>
auto operator ^ (RhsT const& rhs) -> BinaryExpr<LhsT, RhsT const&> const {
- return { static_cast<bool>(m_lhs ^ rhs), m_lhs, "^", rhs };
+ return { static_cast<bool>(m_lhs ^ rhs), m_lhs, "^"_sr, rhs };
}
template<typename RhsT>