Skip to content

Commit

Permalink
refactor: expandedSubsets array simplification from Vishwa
Browse files Browse the repository at this point in the history
Co-authored-by: Vishwa Shah <vishwa2710@gmail.com>
  • Loading branch information
kyle-cochran and vishwa2710 committed Oct 11, 2023
1 parent afbc822 commit b969467
Showing 1 changed file with 1 addition and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -208,11 +208,7 @@ const StateBuilder StateBuilder::expand(const Shared<const CoordinatesSubset>& a
throw ostk::core::error::RuntimeError("Duplicate CoordinatesSubset: [{}]", aCoordinatesSubsetSPtr->getName());
}

Array<Shared<const CoordinatesSubset>> expandedSubsets = Array<Shared<const CoordinatesSubset>>::Empty();
for (const auto& subset : this->coordinatesBrokerSPtr_->getSubsets())
{
expandedSubsets.add(subset);
}
Array<Shared<const CoordinatesSubset>> expandedSubsets = coordinatesBrokerSPtr_->getSubsets();
expandedSubsets.add(aCoordinatesSubsetSPtr);

return StateBuilder(this->frameSPtr_, expandedSubsets);
Expand Down

0 comments on commit b969467

Please sign in to comment.