aboutsummaryrefslogtreecommitdiffhomepage
path: root/Firestore/core/src/firebase/firestore/model/field_value.h
diff options
context:
space:
mode:
Diffstat (limited to 'Firestore/core/src/firebase/firestore/model/field_value.h')
-rw-r--r--Firestore/core/src/firebase/firestore/model/field_value.h9
1 files changed, 9 insertions, 0 deletions
diff --git a/Firestore/core/src/firebase/firestore/model/field_value.h b/Firestore/core/src/firebase/firestore/model/field_value.h
index 09c8531..697d5b3 100644
--- a/Firestore/core/src/firebase/firestore/model/field_value.h
+++ b/Firestore/core/src/firebase/firestore/model/field_value.h
@@ -108,6 +108,15 @@ class FieldValue {
return tag_;
}
+ /**
+ * PORTING NOTE: This deviates from the other platforms that define TypeOrder.
+ * Since we already define Type for union types, we use it together with this
+ * function to achieve the equivalent order of types i.e.
+ * i) if two types are comparable, then they are of equal order;
+ * ii) otherwise, their order is the same as the order of their Type.
+ */
+ static bool Comparable(Type lhs, Type rhs);
+
bool boolean_value() const {
HARD_ASSERT(tag_ == Type::Boolean);
return boolean_value_;