localrepo: remove unused repo.branchtags()/_branchtip() methods
authorBrodie Rao <brodie@sf.io>
Mon, 16 Sep 2013 01:08:29 -0700
changeset 20195 4274eda143cb
parent 20194 9985e188d940
child 20196 59198508b0bd
localrepo: remove unused repo.branchtags()/_branchtip() methods
mercurial/localrepo.py
--- a/mercurial/localrepo.py	Mon Sep 16 01:08:29 2013 -0700
+++ b/mercurial/localrepo.py	Mon Sep 16 01:08:29 2013 -0700
@@ -659,16 +659,6 @@
         branchmap.updatecache(self)
         return self._branchcaches[self.filtername]
 
-
-    def _branchtip(self, heads):
-        '''return the tipmost branch head in heads'''
-        tip = heads[-1]
-        for h in reversed(heads):
-            if not self[h].closesbranch():
-                tip = h
-                break
-        return tip
-
     def branchtip(self, branch):
         '''return the tip node for a given branch'''
         try:
@@ -676,14 +666,6 @@
         except KeyError:
             raise error.RepoLookupError(_("unknown branch '%s'") % branch)
 
-    def branchtags(self):
-        '''return a dict where branch names map to the tipmost head of
-        the branch, open heads come before closed'''
-        bt = {}
-        for bn, heads in self.branchmap().iteritems():
-            bt[bn] = self._branchtip(heads)
-        return bt
-
     def lookup(self, key):
         return self[key].node()