cpython/Misc/NEWS.d/next/Library/2018-02-25-13-47-48.bpo-329...

7 lines
387 B
ReStructuredText

Remove the tri-state parameter "hash", and add the boolean "unsafe_hash". If
unsafe_hash is True, add a __hash__ function, but if a __hash__ exists,
raise TypeError. If unsafe_hash is False, add a __hash__ based on the
values of eq= and frozen=. The unsafe_hash=False behavior is the same as
the old hash=None behavior. unsafe_hash=False is the default, just as
hash=None used to be.