diff --git a/src/storage/expressions/ToExprtkStringVisitor.cpp b/src/storage/expressions/ToExprtkStringVisitor.cpp index 9a1aac389..f3a89b2c5 100644 --- a/src/storage/expressions/ToExprtkStringVisitor.cpp +++ b/src/storage/expressions/ToExprtkStringVisitor.cpp @@ -7,7 +7,8 @@ namespace storm { } std::string ToExprtkStringVisitor::toString(BaseExpression const* expression) { - stream = std::stringstream(); + stream.str(""); + stream.clear(); expression->accept(*this); return std::move(stream.str()); }