How does a generator object refer to itself?

Russell russell_turpin at hotmail.com
Fri May 26 12:08:01 EDT 2006


> Why don't you use a class ?

Because we use this pattern for thousands of functions,
and don't want thousands of new classes. Right now
we use a single class that creates an instance for each
such generator. I was hoping to find a way to get even
more lightweight than that. :-)




More information about the Python-list mailing list