##// END OF EJS Templates
index: use `index.get_rev` in `rebase._computeobsoletenotrebased`...
marmoute -
r43967:0fea0392 default
parent child Browse files
Show More
@@ -2218,7 +2218,7 b' def _computeobsoletenotrebased(repo, reb'
2218
2218
2219 assert repo.filtername is None
2219 assert repo.filtername is None
2220 cl = repo.changelog
2220 cl = repo.changelog
2221 nodemap = cl.nodemap
2221 get_rev = cl.index.get_rev
2222 extinctrevs = set(repo.revs(b'extinct()'))
2222 extinctrevs = set(repo.revs(b'extinct()'))
2223 for srcrev in rebaseobsrevs:
2223 for srcrev in rebaseobsrevs:
2224 srcnode = cl.node(srcrev)
2224 srcnode = cl.node(srcrev)
@@ -2226,7 +2226,8 b' def _computeobsoletenotrebased(repo, reb'
2226 successors = set(obsutil.allsuccessors(repo.obsstore, [srcnode]))
2226 successors = set(obsutil.allsuccessors(repo.obsstore, [srcnode]))
2227 # obsutil.allsuccessors includes node itself
2227 # obsutil.allsuccessors includes node itself
2228 successors.remove(srcnode)
2228 successors.remove(srcnode)
2229 succrevs = {nodemap[s] for s in successors if s in nodemap}
2229 succrevs = {get_rev(s) for s in successors}
2230 succrevs.discard(None)
2230 if succrevs.issubset(extinctrevs):
2231 if succrevs.issubset(extinctrevs):
2231 # all successors are extinct
2232 # all successors are extinct
2232 obsoleteextinctsuccessors.add(srcrev)
2233 obsoleteextinctsuccessors.add(srcrev)
General Comments 0
You need to be logged in to leave comments. Login now