mirror of
https://github.com/rakshasa/rtorrent.git
synced 2026-08-12 05:02:31 +00:00
replace for_each with range loops
No advantage over the latter, which is simpler. Signed-off-by: Rosen Penev <rosenp@gmail.com>
This commit is contained in:
committed by
Jari Sundell
parent
8b663dd169
commit
84c0d516ef
@@ -45,7 +45,8 @@ namespace display {
|
||||
|
||||
void
|
||||
TextElementList::clear() {
|
||||
std::for_each(begin(), end(), [](TextElement* t) { delete t; });
|
||||
for (auto t : *this)
|
||||
delete t;
|
||||
base_type::clear();
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user