@@ -906,8 +906,6 @@ class ConjunctionStep : public BindingStep<ConjunctionElementProducer> {
906906
907907 // / Best solution solver reached so far.
908908 std::optional<Score> BestScore;
909- // / The score established before conjunction is attempted.
910- Score CurrentScore;
911909
912910 // / The number of constraint solver scopes already explored
913911 // / before accepting this conjunction.
@@ -949,7 +947,7 @@ class ConjunctionStep : public BindingStep<ConjunctionElementProducer> {
949947 SmallVectorImpl<Solution> &solutions)
950948 : BindingStep(cs, {cs, conjunction},
951949 conjunction->isIsolated () ? IsolatedSolutions : solutions),
952- BestScore(getBestScore()), CurrentScore(getCurrentScore()),
950+ BestScore(getBestScore()),
953951 OuterScopeCount(cs.CountScopes, 0 ), Conjunction(conjunction),
954952 AfterConjunction(erase(conjunction)), OuterSolutions(solutions) {
955953 assert (conjunction->getKind () == ConstraintKind::Conjunction);
@@ -975,11 +973,8 @@ class ConjunctionStep : public BindingStep<ConjunctionElementProducer> {
975973
976974 // Restore best score only if conjunction fails because
977975 // successful outcome should keep a score set by `restoreOuterState`.
978- if (HadFailure) {
979- auto solutionScore = Score ();
976+ if (HadFailure)
980977 restoreBestScore ();
981- restoreCurrentScore (solutionScore);
982- }
983978
984979 if (OuterTimeRemaining) {
985980 auto anchor = OuterTimeRemaining->first ;
@@ -1033,7 +1028,6 @@ class ConjunctionStep : public BindingStep<ConjunctionElementProducer> {
10331028private:
10341029 // / Restore best and current scores as they were before conjunction.
10351030 void restoreCurrentScore (const Score &solutionScore) const {
1036- CS.CurrentScore = CurrentScore;
10371031 CS.increaseScore (SK_Fix, Conjunction->getLocator (),
10381032 solutionScore.Data [SK_Fix]);
10391033 CS.increaseScore (SK_Hole, Conjunction->getLocator (),
0 commit comments