equal
deleted
inserted
replaced
450 """ |
450 """ |
451 find the common ancestor file context, if any, of self, and fc2 |
451 find the common ancestor file context, if any, of self, and fc2 |
452 """ |
452 """ |
453 |
453 |
454 actx = self.changectx().ancestor(fc2.changectx()) |
454 actx = self.changectx().ancestor(fc2.changectx()) |
455 if self.path() in actx: |
455 |
|
456 # the trivial case: changesets are unrelated, files must be too |
|
457 if not actx: |
|
458 return None |
|
459 |
|
460 # the easy case: no (relevant) renames |
|
461 if fc2.path() == self.path() and self.path() in actx: |
456 return actx[self.path()] |
462 return actx[self.path()] |
457 |
|
458 acache = {} |
463 acache = {} |
459 |
464 |
460 # prime the ancestor cache for the working directory |
465 # prime the ancestor cache for the working directory |
461 for c in (self, fc2): |
466 for c in (self, fc2): |
462 if c._filerev is None: |
467 if c._filerev is None: |