The built-ins aren't mutable, and the singletons are each immutable
and/or unique; so in no case do objects that are both different and
mutable have the same ID.
I know. :-)
Although I have no idea how it is that `id({}) == id({})` as a prior
posted showed; FWIW, I can't manage to reproduce that outcome.
Yes, that was the question. I mean, I thought that the id() function can be used to tell if two mutable objects are different or not. But apparently it cannot. Then why is it there, and what is it for?
--
http://mail.python.org/mailman/listinfo/python-list

Reply via email to