PEP 479: Use the return-keyword instead of raising StopIteration inside a generators.

This commit is contained in:
Raymond Hettinger 2014-11-22 22:14:41 -08:00
parent 828d932a2c
commit bb6c0aaebf
6 changed files with 4 additions and 7 deletions

View file

@ -1949,7 +1949,7 @@ class _ProxyFile:
while True:
line = self.readline()
if not line:
raise StopIteration
return
yield line
def tell(self):