--- a/mercurial/configitems.py Fri Jun 30 03:39:10 2017 +0200
+++ b/mercurial/configitems.py Fri Jun 30 03:43:13 2017 +0200
@@ -302,6 +302,9 @@
coreconfigitem('merge', 'followcopies',
default=True,
)
+coreconfigitem('merge', 'preferancestor',
+ default=lambda: ['*'],
+)
coreconfigitem('pager', 'ignore',
default=list,
)
--- a/mercurial/context.py Fri Jun 30 03:39:10 2017 +0200
+++ b/mercurial/context.py Fri Jun 30 03:43:13 2017 +0200
@@ -659,7 +659,7 @@
anc = cahs[0]
else:
# experimental config: merge.preferancestor
- for r in self._repo.ui.configlist('merge', 'preferancestor', ['*']):
+ for r in self._repo.ui.configlist('merge', 'preferancestor'):
try:
ctx = changectx(self._repo, r)
except error.RepoLookupError:
--- a/mercurial/merge.py Fri Jun 30 03:39:10 2017 +0200
+++ b/mercurial/merge.py Fri Jun 30 03:43:13 2017 +0200
@@ -1566,7 +1566,7 @@
p2 = repo[node]
if pas[0] is None:
- if repo.ui.configlist('merge', 'preferancestor', ['*']) == ['*']:
+ if repo.ui.configlist('merge', 'preferancestor') == ['*']:
cahs = repo.changelog.commonancestorsheads(p1.node(), p2.node())
pas = [repo[anc] for anc in (sorted(cahs) or [nullid])]
else: