rewrite: don't collect set of heads to add unnecessarily

This commit is contained in:
Martin von Zweigbergk 2024-03-29 23:33:48 -07:00 committed by Martin von Zweigbergk
parent c40949208b
commit bfa43d16f9

View file

@ -493,11 +493,10 @@ impl<'settings, 'repo> DescendantRebaser<'settings, 'repo> {
let heads_to_add_expression = old_commits_expression
.parents()
.minus(&old_commits_expression);
let heads_to_add: HashSet<_> = heads_to_add_expression
let heads_to_add = heads_to_add_expression
.evaluate_programmatic(self.mut_repo)
.unwrap()
.iter()
.collect();
.iter();
let mut view = self.mut_repo.view().store_view().clone();
for commit_id in self.mut_repo.parent_mapping.keys() {