aboutsummaryrefslogtreecommitdiff
path: root/core/pair.h
diff options
context:
space:
mode:
authorRémi Verschelde2017-09-01 13:09:30 +0200
committerGitHub2017-09-01 13:09:30 +0200
commit1e0fc4dc4e3143d2905d754099dff5f911188e49 (patch)
tree4745149b48642f4e59616018f1054626064e57b0 /core/pair.h
parent7c76e0c8c3dda5c88f761176cb93445b3214ea21 (diff)
parent8d26748f809e715c42982ebece3fa19c667a9b90 (diff)
downloadgodot-1e0fc4dc4e3143d2905d754099dff5f911188e49.tar.gz
godot-1e0fc4dc4e3143d2905d754099dff5f911188e49.tar.zst
godot-1e0fc4dc4e3143d2905d754099dff5f911188e49.zip
Diffstat (limited to 'core/pair.h')
-rw-r--r--core/pair.h10
1 files changed, 10 insertions, 0 deletions
diff --git a/core/pair.h b/core/pair.h
index f780c79c8..535c3355b 100644
--- a/core/pair.h
+++ b/core/pair.h
@@ -44,6 +44,16 @@ struct Pair {
};
template <class F, class S>
+bool operator==(const Pair<F, S> &pair, const Pair<F, S> &other) {
+ return (pair.first == other.first) && (pair.second == other.second);
+}
+
+template <class F, class S>
+bool operator!=(const Pair<F, S> &pair, const Pair<F, S> &other) {
+ return (pair.first != other.first) || (pair.second != other.second);
+}
+
+template <class F, class S>
struct PairSort {
bool operator()(const Pair<F, S> &A, const Pair<F, S> &B) const {