Re: Why require __init__ to return None?
Steven Miale (smiale@cs.indiana.edu)
Fri, 27 May 1994 11:14:58 -0500
In article <9405271527.AA04685=guido@voorn.cwi.nl>,
<Guido.van.Rossum@cwi.nl> wrote:
>> I am trying to write a generator that is initialized with a list
>> and then returns each element sequentially.
>
>A solution without changing the interpreter is to rename your class to
>_Iterator and have a (global) function as follows:
>
> def Iterator(list):
> return _Iterator(list).generator
Thanks; I figured it out about a minute after posting the original
message.
Steve
--
Steven Miale - smiale@cs.indiana.edu | Don't blame me -
Indiana University, Bloomington, IN | I voted Libertarian.