diff mercurial/context.py @ 37218:97ab6f2dc3c3

context: drop support for changeid of type long (API?) I don't see a reason to support type long. It's pretty much the same type as int. There was some discussion about it on the mailing list around the time of ff2f90503d64 (context: work around `long` not existing on Python 3, 2017-03-11), but I couldn't find a good reason to keep it. There was some mention of hgtk doing "repo[long(rev)]", but that was in 2012. Differential Revision: https://phab.mercurial-scm.org/D2989
author Martin von Zweigbergk <martinvonz@google.com>
date Fri, 30 Mar 2018 22:46:22 -0700
parents fbe34945220d
children de4849b67fe0
line wrap: on
line diff
--- a/mercurial/context.py	Sat Mar 31 00:02:31 2018 -0400
+++ b/mercurial/context.py	Fri Mar 30 22:46:22 2018 -0700
@@ -419,8 +419,6 @@
                 self._node = repo.changelog.node(changeid)
                 self._rev = changeid
                 return
-            if not pycompat.ispy3 and isinstance(changeid, long):
-                changeid = "%d" % changeid
             if changeid == 'null':
                 self._node = nullid
                 self._rev = nullrev