bookmark: simplify mutability check in `validdest`
There is no need to check phase by hand. We already have a ctx method for that.
--- a/mercurial/bookmarks.py Wed Nov 07 09:59:46 2012 -0800
+++ b/mercurial/bookmarks.py Wed Oct 24 17:26:40 2012 +0200
@@ -7,7 +7,7 @@
from mercurial.i18n import _
from mercurial.node import hex
-from mercurial import encoding, error, util, obsolete, phases
+from mercurial import encoding, error, util, obsolete
import errno, os
def read(repo):
@@ -264,7 +264,7 @@
plen = len(validdests)
succs = set(c.node() for c in validdests)
for c in validdests:
- if c.phase() > phases.public:
+ if c.mutable():
# obsolescence marker does not apply to public changeset
succs.update(obsolete.allsuccessors(repo.obsstore,
[c.node()]))