|
|
@@ -434,6 +434,10 @@ coreml.MapType = class {
|
|
|
this.valueType = valueType;
|
|
|
}
|
|
|
|
|
|
+ equals(obj) {
|
|
|
+ return obj instanceof coreml.MapType && this.keyType.equals(obj.keyType) && this.valueType.equals(obj.valueType);
|
|
|
+ }
|
|
|
+
|
|
|
toString() {
|
|
|
return `map<${this.keyType},${this.valueType}>`;
|
|
|
}
|
|
|
@@ -445,6 +449,10 @@ coreml.SequenceType = class {
|
|
|
this.type = type;
|
|
|
}
|
|
|
|
|
|
+ equals(obj) {
|
|
|
+ return obj instanceof coreml.SequenceType && this.type.equals(obj.type);
|
|
|
+ }
|
|
|
+
|
|
|
toString() {
|
|
|
return `sequence<${this.type}>`;
|
|
|
}
|
|
|
@@ -488,6 +496,10 @@ coreml.OptionalType = class {
|
|
|
this.type = type;
|
|
|
}
|
|
|
|
|
|
+ equals(obj) {
|
|
|
+ return obj instanceof coreml.OptionalType && this.type.equals(obj.type);
|
|
|
+ }
|
|
|
+
|
|
|
toString() {
|
|
|
return `optional<${this.type}>`;
|
|
|
}
|