diff --git a/src/storm-parsers/api/model_descriptions.cpp b/src/storm-parsers/api/model_descriptions.cpp index 098ce5952..db617acef 100644 --- a/src/storm-parsers/api/model_descriptions.cpp +++ b/src/storm-parsers/api/model_descriptions.cpp @@ -3,6 +3,8 @@ #include "storm-parsers/parser/PrismParser.h" #include "storm-parsers/parser/JaniParser.h" +#include "storm/api/properties.h" + #include "storm/storage/jani/Model.h" #include "storm/storage/jani/Property.h" @@ -47,13 +49,17 @@ namespace storm { std::pair> parseJaniModel(std::string const& filename, boost::optional> const& propertyFilter) { bool parseProperties = !propertyFilter.is_initialized() || !propertyFilter.get().empty(); auto modelAndFormulae = storm::parser::JaniParser::parse(filename, parseProperties); - return filterProperties(modelAndFormulae, propertyFilter); + filterProperties(modelAndFormulae, propertyFilter); + modelAndFormulae.second = storm::api::substituteConstantsInProperties(modelAndFormulae.second, modelAndFormulae.first.getConstantsSubstitution()); + return modelAndFormulae; } std::pair> parseJaniModelFromString(std::string const& jsonstring, boost::optional> const& propertyFilter) { bool parseProperties = !propertyFilter.is_initialized() || !propertyFilter.get().empty(); auto modelAndFormulae = storm::parser::JaniParser::parseFromString(jsonstring, parseProperties); - return filterProperties(modelAndFormulae, propertyFilter); + filterProperties(modelAndFormulae, propertyFilter); + modelAndFormulae.second = storm::api::substituteConstantsInProperties(modelAndFormulae.second, modelAndFormulae.first.getConstantsSubstitution()); + return modelAndFormulae; } std::pair> parseJaniModel(std::string const& filename, storm::jani::ModelFeatures const& supportedFeatures, boost::optional> const& propertyFilter) {