summaryrefslogtreecommitdiff
path: root/modules
diff options
context:
space:
mode:
Diffstat (limited to 'modules')
-rw-r--r--modules/codec/c++/data.hpp12
1 files changed, 11 insertions, 1 deletions
diff --git a/modules/codec/c++/data.hpp b/modules/codec/c++/data.hpp
index 1c8db80..9934b44 100644
--- a/modules/codec/c++/data.hpp
+++ b/modules/codec/c++/data.hpp
@@ -171,10 +171,20 @@ public:
set(get() + static_cast<typename native_data_type<Schema>::type>(1));
return *this;
}
+
+ template<typename Enc>
+ constexpr bool equals(const data<Schema, Enc>& rhs)const{
+ return get() == rhs.get();
+ }
template<typename Enc>
constexpr bool operator==(const data<Schema, Enc>& rhs)const{
- return get() == rhs.get();
+ return equals(rhs);
+ }
+
+ template<typename Enc>
+ constexpr bool operator!=(const data<Schema,Enc>& rhs) const {
+ return get() != rhs.get();
}
template<typename Enc>