See https://trac.sagemath.org/ticket/23324 for some discussion.

Am Donnerstag, 25. Juni 2020 19:19:26 UTC+2 schrieb Nils Bruin:
>
>
>
> On Thursday, June 25, 2020 at 5:00:23 AM UTC-7, Dima Pasechnik wrote:
>>
>>
>> - the problem is that lists are not hashable, and  considered unequal. 
>> The problem is that in general testing objects for equality is far 
>> from obvious, might be algorithmically unsolvable, etc. 
>>
>> Why is Set trying then? I can see in the documentation that "Sets with 
> unhashable objects work, but with less functionality", but as this example 
> shows, it's more "but with misleading functionality". How is this ever 
> useful?
>
> sage: a,b=list(Set([[0],[0]])) 
> sage: a==b 
> True 
>
> I don't know if this is ever useful internally (I doubt it; I expect it 
> mainly makes bugs harder to find), but we should definitely not be exposing 
> this as user interface, Python's own "frozenset" and "set" are better 
> behaved.
>

-- 
You received this message because you are subscribed to the Google Groups 
"sage-devel" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-devel+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/sage-devel/2cc7f9b1-f3e9-4e9d-8f66-8ba93f7d0c8do%40googlegroups.com.

Reply via email to