[Python-bugs-list] [ python-Bugs-510373 ] Make generator factory a type name

noreply@sourceforge.net noreply@sourceforge.net
Tue, 29 Jan 2002 14:16:57 -0800


Bugs item #510373, was opened at 2002-01-29 14:00
You can respond by visiting: 
http://sourceforge.net/tracker/?func=detail&atid=105470&aid=510373&group_id=5470

Category: Python Interpreter Core
Group: Feature Request
Status: Open
Resolution: None
Priority: 5
Submitted By: Raymond Hettinger (rhettinger)
Assigned to: Nobody/Anonymous (nobody)
Summary: Make generator factory a type name

Initial Comment:
Make the generator factory function, iter() a type 
name so that iter==types.GeneratorType.

This extends to interators the convenience given to 
other factor functions:  int, long, float, complex, 
str, unicode, tuple, list, dict, and object.

----------------------------------------------------------------------

Comment By: Nobody/Anonymous (nobody)
Date: 2002-01-29 14:16

Message:
Logged In: NO 

I can't log in (on the road) but this is Guido.

iter() can't be a standard type because it doesn't return
an object of a specific type.  Iterators are described
by a convention (must support next() and __iter__()),
not by a type.

Somebody reject this.


----------------------------------------------------------------------

You can respond by visiting: 
http://sourceforge.net/tracker/?func=detail&atid=105470&aid=510373&group_id=5470