Changes between Version 1 and Version 2 of Ticket #19016, comment 40


Ignore:
Timestamp:
08/17/15 02:59:32 (5 years ago)
Author:
nbruin
Comment:

Legend:

Unmodified
Added
Removed
Modified
  • Ticket #19016, comment 40

    v1 v2  
    1212{{{
    1313def _cache_key(self):
    14     return hash(str(self))
     14    return (self.parent(),str(self))
    1515}}}
    16 and delete the `__hash__`. That should allow most internal usage of elements (in caches), and would free up hash for more properly defined concepts. Note that `_cache_key` is only a failover, so one still can get better performance once one defines a`__hash__`.
     16and delete the `__hash__` (as is the purpose of this ticket). That should allow most internal usage of elements (in caches), and would free up hash for more properly defined concepts. Note that `_cache_key` is only a failover, so one still can get better performance once one defines a`__hash__`.