comparison mercurial/repoview.py @ 38783:e7aa113b14f7

global: use pycompat.xrange() On Python 3, our module importer automatically rewrites xrange() to pycompat.xrange(). We want to move away from the custom importer on Python 3. This commit converts all instances of xrange() to use pycompat.xrange(). Differential Revision: https://phab.mercurial-scm.org/D4032
author Gregory Szorc <gregory.szorc@gmail.com>
date Wed, 01 Aug 2018 13:00:45 -0700
parents 4e790f0966fc
children 781b2720d2ac
comparison
equal deleted inserted replaced
38782:7eba8f83129b 38783:e7aa113b14f7
126 for roots in repo._phasecache.phaseroots[1:]: 126 for roots in repo._phasecache.phaseroots[1:]:
127 if roots: 127 if roots:
128 firstmutable = min(firstmutable, min(cl.rev(r) for r in roots)) 128 firstmutable = min(firstmutable, min(cl.rev(r) for r in roots))
129 # protect from nullrev root 129 # protect from nullrev root
130 firstmutable = max(0, firstmutable) 130 firstmutable = max(0, firstmutable)
131 return frozenset(xrange(firstmutable, len(cl))) 131 return frozenset(pycompat.xrange(firstmutable, len(cl)))
132 132
133 # function to compute filtered set 133 # function to compute filtered set
134 # 134 #
135 # When adding a new filter you MUST update the table at: 135 # When adding a new filter you MUST update the table at:
136 # mercurial.branchmap.subsettable 136 # mercurial.branchmap.subsettable