diff --git a/search/PathGroup.cc b/search/PathGroup.cc index fc0c22fd..ad359d04 100644 --- a/search/PathGroup.cc +++ b/search/PathGroup.cc @@ -160,11 +160,8 @@ void PathGroup::pushEnds(PathEndSeq *path_ends) { ensureSortedMaxPaths(); - PathEndSeq::Iterator iter(path_ends_); - while (iter.hasNext()) { - PathEnd *path_end = iter.next(); + for (PathEnd *path_end : path_ends_) path_ends->push_back(path_end); - } } PathGroupIterator *