From e1395684931a0c5991248435f1d47ff0425d326d Mon Sep 17 00:00:00 2001 From: Zac Medico Date: Wed, 20 Jun 2012 14:23:47 -0700 Subject: [PATCH] backtracking: only feedback first slot conflict Only create BacktrackNode instances for the first conflict which occurred, since the conflicts that occurred later may have been caused by the first conflict. --- pym/_emerge/resolver/backtracking.py | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) diff --git a/pym/_emerge/resolver/backtracking.py b/pym/_emerge/resolver/backtracking.py index 2f8b6d0b6..e3c5c7d78 100644 --- a/pym/_emerge/resolver/backtracking.py +++ b/pym/_emerge/resolver/backtracking.py @@ -132,12 +132,11 @@ class Backtracker(object): return True def _feedback_slot_conflicts(self, conflicts_data): - # This should be ordered such that the backtracker will - # attempt to solve conflicts which occurred earlier first, - # since an earlier conflict can be the cause of a conflict - # which occurs later. - for slot_data in reversed(conflicts_data): - self._feedback_slot_conflict(slot_data) + # Only create BacktrackNode instances for the first + # conflict which occurred, since the conflicts that + # occurred later may have been caused by the first + # conflict. + self._feedback_slot_conflict(conflicts_data[0]) def _feedback_slot_conflict(self, conflict_data): for pkg, parent_atoms in conflict_data: -- 2.26.2