diff -r 2987726085c6 -r 68fcc5503ec5 mercurial/destutil.py --- a/mercurial/destutil.py Fri Jan 19 17:09:24 2018 +0100 +++ b/mercurial/destutil.py Fri Jan 19 17:29:50 2018 +0100 @@ -359,7 +359,7 @@ def stackbase(ui, repo): revs = stack.getstack(repo) - return revs.last() if revs else None + return revs.first() if revs else None def _statusotherbook(ui, repo): bmheads = bookmarks.headsforactive(repo)