Mercurial > hg
changeset 6196:fc9535ae6fe2
highlight: use iter() instead of generator comprehension
author | Brendan Cully <brendan@kublai.com> |
---|---|
date | Fri, 29 Feb 2008 11:13:50 -0800 |
parents | 272fd5fa576d |
children | f6565f7d9489 |
files | hgext/highlight.py |
diffstat | 1 files changed, 1 insertions(+), 1 deletions(-) [+] |
line wrap: on
line diff
--- a/hgext/highlight.py Fri Feb 29 09:54:28 2008 +0100 +++ b/hgext/highlight.py Fri Feb 29 11:13:50 2008 -0800 @@ -73,7 +73,7 @@ # strip wrapping div colorized = colorized[:colorized.find('\n</pre>')] colorized = colorized[colorized.find('<span'):] - coloriter = (l for l in colorized.splitlines()) + coloriter = iter(colorized.splitlines()) filters['colorize'] = lambda x: coloriter.next()