##// END OF EJS Templates
obsutil: rename allprecursors into allpredecessors...
Boris Feld -
r33701:e6d8ee3c default
parent child Browse files
Show More
@@ -41,7 +41,7 b' from mercurial import ('
41 encoding,
41 encoding,
42 error,
42 error,
43 mdiff,
43 mdiff,
44 obsolete,
44 obsutil,
45 patch,
45 patch,
46 registrar,
46 registrar,
47 scmutil,
47 scmutil,
@@ -167,7 +167,7 b' def getoldnodedrevmap(repo, nodelist):'
167 for node in nodelist:
167 for node in nodelist:
168 ctx = unfi[node]
168 ctx = unfi[node]
169 # For tags like "D123", put them into "toconfirm" to verify later
169 # For tags like "D123", put them into "toconfirm" to verify later
170 precnodes = list(obsolete.allprecursors(unfi.obsstore, [node]))
170 precnodes = list(obsutil.allpredecessors(unfi.obsstore, [node]))
171 for n in precnodes:
171 for n in precnodes:
172 if n in nodemap:
172 if n in nodemap:
173 for tag in unfi.nodetags(n):
173 for tag in unfi.nodetags(n):
@@ -949,7 +949,7 b' def _computebumpedset(repo):'
949 # We only evaluate mutable, non-obsolete revision
949 # We only evaluate mutable, non-obsolete revision
950 node = ctx.node()
950 node = ctx.node()
951 # (future) A cache of predecessors may worth if split is very common
951 # (future) A cache of predecessors may worth if split is very common
952 for pnode in obsutil.allprecursors(repo.obsstore, [node],
952 for pnode in obsutil.allpredecessors(repo.obsstore, [node],
953 ignoreflags=bumpedfix):
953 ignoreflags=bumpedfix):
954 prev = torev(pnode) # unfiltered! but so is phasecache
954 prev = torev(pnode) # unfiltered! but so is phasecache
955 if (prev is not None) and (phase(repo, prev) <= public):
955 if (prev is not None) and (phase(repo, prev) <= public):
@@ -102,7 +102,16 b' def closestpredecessors(repo, nodeid):'
102 else:
102 else:
103 stack.append(precnodeid)
103 stack.append(precnodeid)
104
104
105 def allprecursors(obsstore, nodes, ignoreflags=0):
105 def allprecursors(*args, **kwargs):
106 """ (DEPRECATED)
107 """
108 msg = ("'obsutil.allprecursors' is deprecated, "
109 "use 'obsutil.allpredecessors'")
110 util.nouideprecwarn(msg, '4.4')
111
112 return allpredecessors(*args, **kwargs)
113
114 def allpredecessors(obsstore, nodes, ignoreflags=0):
106 """Yield node for every precursors of <nodes>.
115 """Yield node for every precursors of <nodes>.
107
116
108 Some precursors may be unknown locally.
117 Some precursors may be unknown locally.
General Comments 0
You need to be logged in to leave comments. Login now