summaryrefslogtreecommitdiff
path: root/src/bindings/cxx/eo_cxx/eo_wref.hh
diff options
context:
space:
mode:
authorJean-Philippe Andre <jp.andre@samsung.com>2017-11-06 12:26:05 +0900
committerJean-Philippe Andre <jp.andre@samsung.com>2017-11-07 09:57:24 +0900
commit64698daeb5aa5eec5da8cd60ff18c05e2d155102 (patch)
tree29da0b56a047dc5bc2fc176891a0daaa31fdb4c0 /src/bindings/cxx/eo_cxx/eo_wref.hh
parentd4c92b39df3662064be0c002fd6ae2e181f64b75 (diff)
cxx: Add support for operator == with objects
Diffstat (limited to 'src/bindings/cxx/eo_cxx/eo_wref.hh')
-rw-r--r--src/bindings/cxx/eo_cxx/eo_wref.hh12
1 files changed, 12 insertions, 0 deletions
diff --git a/src/bindings/cxx/eo_cxx/eo_wref.hh b/src/bindings/cxx/eo_cxx/eo_wref.hh
index 124b1da3b7..e28409c513 100644
--- a/src/bindings/cxx/eo_cxx/eo_wref.hh
+++ b/src/bindings/cxx/eo_cxx/eo_wref.hh
@@ -135,6 +135,18 @@ struct wref
135 } 135 }
136#endif 136#endif
137 137
138 template <typename U>
139 bool operator == (U const &other) const
140 {
141 return other._eo_ptr() == _eo_wref;
142 }
143
144 template <typename U>
145 friend bool operator == (U const &other, wref<T> const &thiz)
146 {
147 return other._eo_ptr() == thiz._eo_wref;
148 }
149
138private: 150private:
139 void _add() 151 void _add()
140 { 152 {