comparison mercurial/localrepo.py @ 21480:d19f491e5d5b

workingctx: use inheritance for _buildstatus while keeping the fastpath This patch maintains the fast path for workingctx which is to not build a manifest if the working directory is being compared to its parent since, in this case, we can just copy the parent manifest.
author Sean Farley <sean.michael.farley@gmail.com>
date Thu, 24 Apr 2014 08:34:44 -0500
parents e18ef2e11219
children 6adfc311eee8
comparison
equal deleted inserted replaced
21479:e18ef2e11219 21480:d19f491e5d5b
1549 self.ui.warn('%s: %s\n' % (self.dirstate.pathto(f), msg)) 1549 self.ui.warn('%s: %s\n' % (self.dirstate.pathto(f), msg))
1550 match.bad = bad 1550 match.bad = bad
1551 1551
1552 r = [[], [], [], [], [], [], []] 1552 r = [[], [], [], [], [], [], []]
1553 r = ctx2._prestatus(ctx1, r, match, listignored, listclean, listunknown) 1553 r = ctx2._prestatus(ctx1, r, match, listignored, listclean, listunknown)
1554 1554 r = ctx2._buildstatus(ctx1, r, match, listignored, listclean,
1555 if not parentworking: 1555 listunknown)
1556 r = ctx2._buildstatus(ctx1, r, match, listignored, listclean,
1557 listunknown)
1558
1559 r = ctx2._poststatus(ctx1, r, match, listignored, listclean, 1556 r = ctx2._poststatus(ctx1, r, match, listignored, listclean,
1560 listunknown) 1557 listunknown)
1561 1558
1562 if reversed: 1559 if reversed:
1563 # since we are maintaining whether we reversed ctx1 and ctx2 (due 1560 # since we are maintaining whether we reversed ctx1 and ctx2 (due