Skip to content
Snippets Groups Projects
Commit 7eba8f83 authored by Gregory Szorc's avatar Gregory Szorc
Browse files

pycompat: add xrange alias for Python 2

We assign xrange on Python 3 but not Python 2. Adding the missing
symbol on Python 2 allows us to use `pycompat.xrange` to get a
generator range function.

Differential Revision: https://phab.mercurial-scm.org/D4031
parent 0a57945a
Branches
Tags
No related merge requests found
......@@ -331,6 +331,7 @@
else:
import cStringIO
xrange = xrange
unicode = unicode
bytechr = chr
byterepr = repr
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment