From d7cd36a331b9985263697cc0befeb7964a5ba295 Mon Sep 17 00:00:00 2001 From: James Cherry Date: Mon, 6 Jan 2020 19:36:04 -0800 Subject: [PATCH] range iteration --- search/PathGroup.cc | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) 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 *