File tree Expand file tree Collapse file tree 1 file changed +3
-7
lines changed
Expand file tree Collapse file tree 1 file changed +3
-7
lines changed Original file line number Diff line number Diff line change @@ -567,8 +567,7 @@ file_observer_config file_observer_config::parse(const filesystem::path& configP
567567 boost::property_tree::xml_parser::no_comments | boost::property_tree::xml_parser::trim_whitespace);
568568
569569 file_observer_config config;
570- const auto simulators = ptree.get_child (" simulators" );
571- for (const auto & simulator : simulators) {
570+ for (const auto & simulator : ptree.get_child (" simulators" )) {
572571 if (simulator.first == " simulator" ) {
573572 const auto modelName = get_attribute<std::string>(simulator.second , " name" );
574573 const auto decimationFactor = get_optional_attribute<size_t >(simulator.second , " decimationFactor" );
@@ -583,15 +582,12 @@ file_observer_config file_observer_config::parse(const filesystem::path& configP
583582 }
584583 }
585584 if (const auto configuration = ptree.get_child_optional (" configuration" )) {
586- const auto timestamps = get_optional_attribute<bool >(*configuration, " timestampedFilenames" );
587- if (timestamps) {
585+ if (const auto timestamps = get_optional_attribute<bool >(*configuration, " timestampedFilenames" )) {
588586 config.set_timestamped_filenames (*timestamps);
589587 }
590- const auto precision = get_optional_attribute<int >(*configuration, " floatingPointPrecision" );
591- if (precision) {
588+ if (const auto precision = get_optional_attribute<int >(*configuration, " floatingPointPrecision" )) {
592589 config.fixed_precision (*precision);
593590 }
594-
595591 }
596592
597593 return config;
You can’t perform that action at this time.
0 commit comments