From 88c63c305471b27783078ab02854e2a72bc9ce21 Mon Sep 17 00:00:00 2001 From: chriseth Date: Thu, 17 Feb 2022 10:29:58 +0100 Subject: [PATCH] Apply suggestions from code review Co-authored-by: Bhargava Shastry --- libsolutil/LP.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/libsolutil/LP.cpp b/libsolutil/LP.cpp index 41f1f5d34..a62f38aaa 100644 --- a/libsolutil/LP.cpp +++ b/libsolutil/LP.cpp @@ -277,7 +277,7 @@ pair simplexPhaseI(Tableau _tableau) LPResult result; tie(result, _tableau) = simplexEq(move(_tableau)); - solAssert(result == LPResult::Feasible || result == LPResult::Unbounded, ""); + solAssert(result != LPResult::Infeasible, ""); vector optimum = solutionVector(_tableau); @@ -325,7 +325,7 @@ pair> simplex(vector _constraints, Linear // but it might not be optimal. LPResult result; tie(result, tableau) = simplexEq(move(tableau)); - solAssert(result == LPResult::Feasible || result == LPResult::Unbounded, ""); + solAssert(result != LPResult::Infeasible, ""); return make_pair(result, solutionVector(tableau)); }