2280
2280
base_rev_id = graph.find_unique_lca(revision, old_tip)
2281
2281
base_tree = self.branch.repository.revision_tree(base_rev_id)
2282
2282
other_tree = self.branch.repository.revision_tree(old_tip)
2283
2284
result += merge.merge_inner(
2302
2303
or basis.inventory.root.file_id != to_root_id):
2303
2304
self.set_root_id(to_root_id)
2307
graph = self.branch.repository.get_graph()
2308
base_rev_id = graph.find_unique_lca(revision, last_rev)
2309
base_tree = self.branch.repository.revision_tree(base_rev_id)
2305
2313
result += merge.merge_inner(
2309
2317
this_tree=self,
2310
2318
change_reporter=change_reporter)
2311
2319
self.set_last_revision(revision)
2327
2335
last_rev = parent_trees[0][0]
2328
2336
if already_merged:
2329
2337
self.add_parent_tree_id(old_tip)
2331
if (old_tip is not None and not _mod_revision.is_null(old_tip)
2332
and old_tip != last_rev):
2333
# our last revision was not the prior branch last revision
2334
# and we have converted that last revision to a pending merge.
2335
# base is somewhere between the branch tip now
2336
# and the now pending merge
2338
# Since we just modified the working tree and inventory, flush out
2339
# the current state, before we modify it again.
2340
# TODO: jam 20070214 WorkingTree3 doesn't require this, dirstate
2341
# requires it only because TreeTransform directly munges the
2342
# inventory and calls tree._write_inventory(). Ultimately we
2343
# should be able to remove this extra flush.
2345
graph = self.branch.repository.get_graph()
2346
base_rev_id = graph.find_unique_lca(revision, old_tip)
2347
base_tree = self.branch.repository.revision_tree(base_rev_id)
2348
other_tree = self.branch.repository.revision_tree(old_tip)
2349
result += merge.merge_inner(
2354
change_reporter=change_reporter)
2355
self.add_parent_tree_id(old_tip)
2358
2340
def _write_hashcache_if_dirty(self):