phase 1 of addressing cppcheck useStlAlgorithm warnings,

this set only includes fill and copy operations.
This commit is contained in:
G.E
2024-05-14 17:37:38 +03:00
parent 6e306a508e
commit 4cefba5ced
19 changed files with 102 additions and 98 deletions

View File

@@ -89,9 +89,7 @@ public:
/// Set all bits.
void setall() {
for (auto &e : bits) {
e = all_ones;
}
std::fill(bits.begin(), bits.end(), all_ones);
clear_trailer();
}
@@ -102,9 +100,7 @@ public:
/// Clear all bits.
void clear() {
for (auto &e : bits) {
e = 0;
}
std::fill(bits.begin(), bits.end(), 0);
}
/// Clear all bits (alias for bitset::clear).