on Sun Oct 23 2016, milos <swift-users-AT-swift.org> wrote: > Given an array of instances of a `Hashable` value type, all equal > according to `Equatable` protocol, but with distinct `hashValue`s,
Equal hashables must have the same hashValue. If you violate this rule, all bets are off. As the doc says: A hash value, provided by a type's hashValue property, is an integer that is the same for any two instances that compare equally. That is, for two instances a and b of the same type, if a == b then a.hashValue == b.hashValue. https://developer.apple.com/reference/swift/hashable -- -Dave _______________________________________________ swift-users mailing list swift-users@swift.org https://lists.swift.org/mailman/listinfo/swift-users