##// END OF EJS Templates
repo: move unfiltered-repo optimization to workingctx...
Martin von Zweigbergk -
r39995:43d3b09b default
parent child Browse files
Show More
@@ -1241,7 +1241,9 b' class workingctx(committablectx):'
1241 p = self._repo.dirstate.parents()
1241 p = self._repo.dirstate.parents()
1242 if p[1] == nullid:
1242 if p[1] == nullid:
1243 p = p[:-1]
1243 p = p[:-1]
1244 return [self._repo[x] for x in p]
1244 # use unfiltered repo to delay/avoid loading obsmarkers
1245 unfi = self._repo.unfiltered()
1246 return [changectx(self._repo, unfi.changelog.rev(n), n) for n in p]
1245
1247
1246 def _fileinfo(self, path):
1248 def _fileinfo(self, path):
1247 # populate __dict__['_manifest'] as workingctx has no _manifestdelta
1249 # populate __dict__['_manifest'] as workingctx has no _manifestdelta
@@ -1228,8 +1228,7 b' class localrepository(object):'
1228 node = self.changelog.tip()
1228 node = self.changelog.tip()
1229 rev = self.changelog.rev(node)
1229 rev = self.changelog.rev(node)
1230 return context.changectx(self, rev, node)
1230 return context.changectx(self, rev, node)
1231 elif (changeid == '.'
1231 elif changeid == '.':
1232 or self.local() and changeid == self.dirstate.p1()):
1233 # this is a hack to delay/avoid loading obsmarkers
1232 # this is a hack to delay/avoid loading obsmarkers
1234 # when we know that '.' won't be hidden
1233 # when we know that '.' won't be hidden
1235 node = self.dirstate.p1()
1234 node = self.dirstate.p1()
@@ -71,7 +71,6 b' With some node gone missing during the e'
71 $ hg commit --amend -X . -m XXXXXX
71 $ hg commit --amend -X . -m XXXXXX
72 $ hg commit --amend -X . -m b2
72 $ hg commit --amend -X . -m b2
73 $ hg --hidden --config extensions.strip= strip 'desc(XXXXXX)' --no-backup
73 $ hg --hidden --config extensions.strip= strip 'desc(XXXXXX)' --no-backup
74 warning: ignoring unknown working parent aba7da937030!
75 $ hg histedit --continue
74 $ hg histedit --continue
76 $ hg log -G
75 $ hg log -G
77 @ 8:273c1f3b8626 c
76 @ 8:273c1f3b8626 c
@@ -200,5 +200,4 b' actual stripping'
200
200
201 $ hg strip --config extensions.strip= --rev 'desc("c_dH0")'
201 $ hg strip --config extensions.strip= --rev 'desc("c_dH0")'
202 saved backup bundle to $TESTTMP/client/.hg/strip-backup/fe47ea669cea-a41bf5a9-backup.hg
202 saved backup bundle to $TESTTMP/client/.hg/strip-backup/fe47ea669cea-a41bf5a9-backup.hg
203 warning: ignoring unknown working parent 49003e504178!
204
203
General Comments 0
You need to be logged in to leave comments. Login now