In article <mailman.2639.1246802753.8015.python-l...@python.org>, Hendrik van Rooyen <m...@microcorp.co.za> wrote: > >But wait - maybe if he passes an iterator around - the equivalent of >for char in input_stream... Still no good though, unless the next call >to the iterator is faster than an ordinary python call.
Calls to iterators created by generators are indeed faster than an ordinary Python call, because the stack frame is already mostly set up. -- Aahz (a...@pythoncraft.com) <*> http://www.pythoncraft.com/ "as long as we like the same operating system, things are cool." --piranha -- http://mail.python.org/mailman/listinfo/python-list