diff --git a/src/storage/prism/Constant.cpp b/src/storage/prism/Constant.cpp index 3df0a26bc..641336c76 100644 --- a/src/storage/prism/Constant.cpp +++ b/src/storage/prism/Constant.cpp @@ -1,4 +1,6 @@ #include "src/storage/prism/Constant.h" +#include "src/exceptions/ExceptionMacros.h" +#include "src/exceptions/IllegalFunctionCallException.h" namespace storm { namespace prism { @@ -23,6 +25,7 @@ namespace storm { } storm::expressions::Expression const& Constant::getExpression() const { + LOG_THROW(this->isDefined(), storm::exceptions::IllegalFunctionCallException, "Unable to retrieve defining expression for undefined constant."); return this->expression; }