Mercurial > hg
changeset 19500:a96565abbd59 stable
mq: rename next() to nextpatch() to avoid confusing a future check-code patch
next() is a builtin starting in 2.6, so it's also nice to avoid
shadowing the builtin.
author | Augie Fackler <raf@durin42.com> |
---|---|
date | Thu, 25 Jul 2013 10:42:36 -0400 |
parents | 81318ca090a2 |
children | 725507cd5216 |
files | hgext/mq.py |
diffstat | 1 files changed, 3 insertions(+), 3 deletions(-) [+] |
line wrap: on
line diff
--- a/hgext/mq.py Thu Jul 25 15:27:41 2013 +0400 +++ b/hgext/mq.py Thu Jul 25 10:42:36 2013 -0400 @@ -1877,7 +1877,7 @@ index of the first patch past the last applied one. """ end = 0 - def next(start): + def nextpatch(start): if all_patches or start >= len(self.series): return start for i in xrange(start, len(self.series)): @@ -1892,8 +1892,8 @@ end = self.series.index(p) except ValueError: return 0 - return next(end + 1) - return next(end) + return nextpatch(end + 1) + return nextpatch(end) def appliedname(self, index): pname = self.applied[index].name