Show More
@@ -550,19 +550,15 class filectx(object): | |||
|
550 | 550 | return None |
|
551 | 551 | |
|
552 | 552 | def ancestors(self): |
|
553 |
|
|
|
554 |
|
|
|
555 |
while |
|
|
556 |
|
|
|
557 |
|
|
|
558 | # make sure we return ancestors in reverse revision order | |
|
559 | parents = reversed(parents) | |
|
560 | for parent in parents: | |
|
561 | s = str(parent) | |
|
562 | if s not in seen: | |
|
563 | visit.append(parent) | |
|
564 | seen.add(s) | |
|
565 | yield parent | |
|
553 | visit = {} | |
|
554 | c = self | |
|
555 | while True: | |
|
556 | for parent in c.parents(): | |
|
557 | visit[(parent.rev(), parent.node())] = parent | |
|
558 | if not visit: | |
|
559 | break | |
|
560 | c = visit.pop(max(visit)) | |
|
561 | yield c | |
|
566 | 562 | |
|
567 | 563 | class workingctx(changectx): |
|
568 | 564 | """A workingctx object makes access to data related to |
General Comments 0
You need to be logged in to leave comments.
Login now