Do pythons like sugar?

Andrew Dalke adalke at mindspring.com
Fri Jan 10 05:22:55 CET 2003


Geoff Gerrietts wrote:
> Another disclaimer we might like to add is "does not work under
> pythons earlier than 2.2", since it doesn't. dir(self) won't return
> attributes on the class or base classes prior to 2.2.

True.  I was thinking about that later, since the spec (as I
recall) says the behaviour of dir() is undefined.  I should
have used self.__dict__.keys().

However, my actual code would have worked since I was only
referencing instance variables.

					Andrew
					dalke at dalkescientific.com





More information about the Python-list mailing list