Changes between Version 34 and Version 35 of Ticket #19016


Ignore:
Timestamp:
08/16/15 19:10:45 (5 years ago)
Author:
vdelecroix
Comment:

Arghhh... there are two category tests which ask explicitely for parent.one() and parent.zero() to return hashable elements! These are

  • Magmas.Unital.ParentMethods._test_one
  • AdditiveMagmas.AdditiveUnital.ParentMethods._test_zero

(I do think that those tests are good because most of the time the result is cached)

In other words, any (additive or multiplicative) magma element should be immutable or adopt an mutable/immutable framework... might be a lot of work to fix!

Concerning Parent and CategoryObject from which it inherits I do not think it is a good idea to touch it for now. Most of the time we expect a Parent to be immutable.

Legend:

Unmodified
Added
Removed
Modified
  • Ticket #19016

    • Property Summary changed from Better hash for Element and CategoryObject to Better hash for Element
  • Ticket #19016 – Description

    v34 v35  
    1 As reported on sage-devel [1], both `Element` and `CategoryObject` implement their hash based on their string representation. This causes a lot of troubles
     1As reported on sage-devel [1], both `Element` implement their hash based on their string representation. This causes a lot of troubles
    22
    33- it breaks the {{{equality => same hash}}} assumption for finitely presented groups