##// END OF EJS Templates
lookup: optimize '.'...
Matt Mackall -
r6736:369ddc9c default
parent child Browse files
Show More
@@ -442,12 +442,7 b' class localrepository(repo.repository):'
442 442
443 443 def lookup(self, key):
444 444 if key == '.':
445 key, second = self.dirstate.parents()
446 if key == nullid:
447 raise repo.RepoError(_("no revision checked out"))
448 if second != nullid:
449 self.ui.warn(_("warning: working directory has two parents, "
450 "tag '.' uses the first\n"))
445 return self.dirstate.parents()[0]
451 446 elif key == 'null':
452 447 return nullid
453 448 n = self.changelog._match(key)
@@ -150,7 +150,6 b' 2 files updated, 0 files merged, 1 files'
150 150 1 files updated, 0 files merged, 0 files removed, 0 files unresolved
151 151 (branch merge, don't forget to commit)
152 152 % log -r . with two parents
153 warning: working directory has two parents, tag '.' uses the first
154 153 changeset: 3:e62f78d544b4
155 154 parent: 1:3d5bf5654eda
156 155 user: test
@@ -23,7 +23,6 b' M bar'
23 23 M foo1
24 24 foo
25 25 % reverting foo1 and bar
26 warning: working directory has two parents, tag '.' uses the first
27 26 saving current version of bar as bar.orig
28 27 reverting bar
29 28 saving current version of foo1 as foo1.orig
General Comments 0
You need to be logged in to leave comments. Login now