Merge branch 'stl' of git://github.com/neheb/MPD

This commit is contained in:
Max Kellermann
2020-04-08 23:03:44 +02:00
7 changed files with 12 additions and 36 deletions

View File

@@ -113,11 +113,7 @@ public:
#ifndef NDEBUG
gcc_pure
bool IsEmpty() const noexcept {
for (const auto &c : list)
if (!c.IsCancelled())
return false;
return true;
return std::all_of(list.begin(), list.end(), [](const auto &c) { return c.IsCancelled(); });
}
#endif