July 30, 2019
4:10 a.m.
On Fri, Jul 26, 2019, at 05:45, Steven D'Aprano wrote:
Nor should we make too much of the fact that Python sets require elements to be hashable. As Java TreeSet demonstrates, we could get an efficient set of unhashable items if we required orderability; and we can get sets of unhashable, unorderable items if we're willing to compromise on efficiency.
And think of what we could do if we were willing to compromise on immutability of hashable objects (Java does, in general, make the opposite decision there)