--- a/mercurial/bookmarks.py Mon Jul 10 17:04:16 2017 +0200
+++ b/mercurial/bookmarks.py Mon Jul 10 17:08:20 2017 +0200
@@ -739,11 +739,10 @@
if old not in marks:
raise error.Abort(_("bookmark '%s' does not exist") % old)
marks.checkconflict(mark, force)
- marks[mark] = marks[old]
+ changes = [(mark, marks[old]), (old, None)]
+ marks.applychanges(repo, tr, changes)
if repo._activebookmark == old and not inactive:
activate(repo, mark)
- del marks[old]
- marks.recordchange(tr)
def addbookmarks(repo, tr, names, rev=None, force=False, inactive=False):
"""add a list of bookmarks