Mercurial > public > mercurial-scm > hg
comparison mercurial/policy.py @ 38850:6104b203bec8
index: replace insert(-1, e) method by append(e) method
I want to make index[len(index) - 1] be the tip revision, not null
revision as it is today. insert(-1, e) will then make little
sense. Since insert() currently requires the first argument to be -1,
it seems simpler to replace it by a method that allows insertion only
at the end.
Note that revlogoldindex already has this method (by virtue of
extending list).
Differential Revision: https://phab.mercurial-scm.org/D4021
author | Martin von Zweigbergk <martinvonz@google.com> |
---|---|
date | Wed, 01 Aug 2018 10:57:14 -0700 |
parents | 0304f22497fa |
children | 781b2720d2ac |
comparison
equal
deleted
inserted
replaced
38849:da5a666f0f78 | 38850:6104b203bec8 |
---|---|
67 _cextversions = { | 67 _cextversions = { |
68 (r'cext', r'base85'): 1, | 68 (r'cext', r'base85'): 1, |
69 (r'cext', r'bdiff'): 3, | 69 (r'cext', r'bdiff'): 3, |
70 (r'cext', r'mpatch'): 1, | 70 (r'cext', r'mpatch'): 1, |
71 (r'cext', r'osutil'): 4, | 71 (r'cext', r'osutil'): 4, |
72 (r'cext', r'parsers'): 5, | 72 (r'cext', r'parsers'): 6, |
73 } | 73 } |
74 | 74 |
75 # map import request to other package or module | 75 # map import request to other package or module |
76 _modredirects = { | 76 _modredirects = { |
77 (r'cext', r'charencode'): (r'cext', r'parsers'), | 77 (r'cext', r'charencode'): (r'cext', r'parsers'), |