diff --git a/src/builder/jit/ExplicitJitJaniModelBuilder.cpp b/src/builder/jit/ExplicitJitJaniModelBuilder.cpp index 6a7aaaa83..8d289f6d1 100644 --- a/src/builder/jit/ExplicitJitJaniModelBuilder.cpp +++ b/src/builder/jit/ExplicitJitJaniModelBuilder.cpp @@ -519,19 +519,23 @@ namespace storm { auto start = std::chrono::high_resolution_clock::now(); std::shared_ptr>> sparseModel(nullptr); + boost::optional error; try { sparseModel = std::shared_ptr>>(builder->build()); STORM_LOG_THROW(sparseModel, storm::exceptions::UnexpectedException, "An unexpected error occurred."); STORM_LOG_TRACE("Successfully got model from jit-builder."); } catch (std::exception const& e) { - STORM_LOG_THROW(false, storm::exceptions::WrongFormatException, "Model building failed. Reason: " << e.what()); + error = e.what(); } + auto end = std::chrono::high_resolution_clock::now(); STORM_LOG_TRACE("Building model took " << std::chrono::duration_cast(end - start).count() << "ms."); // (7) Delete the shared library. boost::filesystem::remove(dynamicLibraryPath); + STORM_LOG_THROW(!error, storm::exceptions::WrongFormatException, "Model building failed. Reason: " << error.get()); + // Return the constructed model. return sparseModel; } diff --git a/test/functional/storage/SylvanDdTest.cpp b/test/functional/storage/SylvanDdTest.cpp index fdb60e5c0..57ec530d9 100644 --- a/test/functional/storage/SylvanDdTest.cpp +++ b/test/functional/storage/SylvanDdTest.cpp @@ -291,7 +291,6 @@ TEST(SylvanDd, AddIteratorTest) { ASSERT_NO_THROW(ite = dd.end()); std::pair valuationValuePair; uint_fast64_t numberOfValuations = 0; - dd.exportToDot("dd.dot"); while (it != ite) { ASSERT_NO_THROW(valuationValuePair = *it); ASSERT_NO_THROW(++it); @@ -411,4 +410,4 @@ TEST(SylvanDd, BddOddTest) { EXPECT_EQ(9ul, matrix.getRowGroupCount()); EXPECT_EQ(9ul, matrix.getColumnCount()); EXPECT_EQ(106ul, matrix.getNonzeroEntryCount()); -} \ No newline at end of file +}