[Python-checkins] python/dist/src/Lib cgi.py,1.74,1.75
gvanrossum@users.sourceforge.net
gvanrossum@users.sourceforge.net
Wed, 11 Sep 2002 11:20:41 -0700
Update of /cvsroot/python/python/dist/src/Lib
In directory usw-pr-cvs1:/tmp/cvs-serv19688
Modified Files:
cgi.py
Log Message:
Patch suggested by Hamish Lawson: add an __iter__() that returns
iter(self.keys()).
Index: cgi.py
===================================================================
RCS file: /cvsroot/python/python/dist/src/Lib/cgi.py,v
retrieving revision 1.74
retrieving revision 1.75
diff -C2 -d -r1.74 -r1.75
*** cgi.py 30 Jun 2002 03:39:14 -0000 1.74
--- cgi.py 11 Sep 2002 18:20:34 -0000 1.75
***************
*** 526,529 ****
--- 526,532 ----
`self.name`, `self.filename`, `self.value`)
+ def __iter__(self):
+ return iter(self.keys())
+
def __getattr__(self, name):
if name != 'value':