From 7e65e797fab35bb698bebc0a50318e8a03a77f63 Mon Sep 17 00:00:00 2001 From: Tim Quatmann Date: Wed, 5 Aug 2020 11:40:43 +0200 Subject: [PATCH] SingleValueModelCheckerHelper: Fixed signature of getOptimizationDirection so that a const& is returned. --- src/storm/modelchecker/helper/SingleValueModelCheckerHelper.cpp | 2 +- src/storm/modelchecker/helper/SingleValueModelCheckerHelper.h | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/storm/modelchecker/helper/SingleValueModelCheckerHelper.cpp b/src/storm/modelchecker/helper/SingleValueModelCheckerHelper.cpp index 845543f26..b884d6ee2 100644 --- a/src/storm/modelchecker/helper/SingleValueModelCheckerHelper.cpp +++ b/src/storm/modelchecker/helper/SingleValueModelCheckerHelper.cpp @@ -21,7 +21,7 @@ namespace storm { } template - storm::solver::OptimizationDirection SingleValueModelCheckerHelper::getOptimizationDirection() const { + storm::solver::OptimizationDirection const& SingleValueModelCheckerHelper::getOptimizationDirection() const { STORM_LOG_ASSERT(isOptimizationDirectionSet(), "Requested optimization direction but none was set."); return _optimizationDirection.get(); } diff --git a/src/storm/modelchecker/helper/SingleValueModelCheckerHelper.h b/src/storm/modelchecker/helper/SingleValueModelCheckerHelper.h index 67bb2b7df..83ea27ae0 100644 --- a/src/storm/modelchecker/helper/SingleValueModelCheckerHelper.h +++ b/src/storm/modelchecker/helper/SingleValueModelCheckerHelper.h @@ -41,7 +41,7 @@ namespace storm { * @pre an optimization direction has to be set before calling this. * @return the optimization direction. */ - storm::solver::OptimizationDirection getOptimizationDirection() const; + storm::solver::OptimizationDirection const& getOptimizationDirection() const; /*! * @pre an optimization direction has to be set before calling this.