From dab8f985dbf0310a7338e15e85f9268649540293 Mon Sep 17 00:00:00 2001 From: Daniel Schemmel Date: Fri, 24 Mar 2023 15:01:00 +0000 Subject: use unique_ptr in IndependentSolver --- lib/Solver/IndependentSolver.cpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'lib') diff --git a/lib/Solver/IndependentSolver.cpp b/lib/Solver/IndependentSolver.cpp index 812aefb6..007bfdcb 100644 --- a/lib/Solver/IndependentSolver.cpp +++ b/lib/Solver/IndependentSolver.cpp @@ -21,7 +21,9 @@ #include #include +#include #include +#include #include using namespace klee; @@ -388,12 +390,10 @@ void calculateArrayReferences(const IndependentElementSet & ie, class IndependentSolver : public SolverImpl { private: - Solver *solver; + std::unique_ptr solver; public: - IndependentSolver(Solver *_solver) - : solver(_solver) {} - ~IndependentSolver() { delete solver; } + IndependentSolver(Solver *_solver) : solver(_solver) {} bool computeTruth(const Query&, bool &isValid); bool computeValidity(const Query&, Solver::Validity &result); -- cgit 1.4.1