hashability

Asun Friere afriere at yahoo.co.uk
Wed Aug 12 03:25:06 EDT 2009


On Aug 12, 5:14 pm, Dennis Lee Bieber <wlfr... at ix.netcom.com> wrote:

> c1 = C()
> c2 = C()
>
> {c1:4}[c2]
>
> to behave? That IS the equivalent of your statement -- two instances are
> two distinctly different entities...
>

Thankyou, that is EXACTLY the mistake I made that sent me off into
lunacy.

At the risk of further embarassment, the answer is that one would
expect it to behave analogously to:

c1 = int(x)
c2 = int(x)

{c1:4}[c2]

Or is my brain still on vacation?



More information about the Python-list mailing list