[py-svn] r36380 - in py/dist/py: path/svn rest

cfbolz at codespeak.net cfbolz at codespeak.net
Tue Jan 9 18:04:56 CET 2007


Author: cfbolz
Date: Tue Jan  9 18:04:55 2007
New Revision: 36380

Modified:
   py/dist/py/path/svn/wccommand.py
   py/dist/py/rest/rst.py
Log:
use our own version of enumerate


Modified: py/dist/py/path/svn/wccommand.py
==============================================================================
--- py/dist/py/path/svn/wccommand.py	(original)
+++ py/dist/py/path/svn/wccommand.py	Tue Jan  9 18:04:55 2007
@@ -314,7 +314,8 @@
         result = []
         blamelines = out.splitlines()
         reallines = py.path.svnurl(self.url).readlines()
-        for i, (blameline, line) in enumerate(zip(blamelines, reallines)):
+        for i, (blameline, line) in py.builtin.enumerate(
+                zip(blamelines, reallines)):
             m = rex_blame.match(blameline)
             if not m:
                 raise ValueError("output line %r of svn blame does not match "

Modified: py/dist/py/rest/rst.py
==============================================================================
--- py/dist/py/rest/rst.py	(original)
+++ py/dist/py/rest/rst.py	Tue Jan  9 18:04:55 2007
@@ -156,7 +156,7 @@
     def __init__(self, *args, **kwargs):
         # make shortcut
         args = list(args)
-        for num, arg in enumerate(args):
+        for num, arg in py.builtin.enumerate(args):
             if isinstance(arg, str):
                 args[num] = Text(arg)
         super(Paragraph, self).__init__(*args, **kwargs)
@@ -247,7 +247,7 @@
 
     def text(self):
         text = self.escape(self._text).split('\n')
-        for i, line in enumerate(text):
+        for i, line in py.builtin.enumerate(text):
             if line.strip():
                 text[i] = '  %s' % (line,)
         return self.start + '\n'.join(text)



More information about the pytest-commit mailing list