diff options
Diffstat (limited to 'src/sticker')
-rw-r--r-- | src/sticker/Database.cxx | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/src/sticker/Database.cxx b/src/sticker/Database.cxx index c90cbdcf7..29df8ca8e 100644 --- a/src/sticker/Database.cxx +++ b/src/sticker/Database.cxx @@ -22,10 +22,11 @@ #include "lib/sqlite/Util.hxx" #include "fs/Path.hxx" #include "Idle.hxx" -#include "util/Macros.hxx" #include "util/StringCompare.hxx" #include "util/ScopeExit.hxx" +#include <iterator> + #include <assert.h> using namespace Sqlite; @@ -98,7 +99,7 @@ StickerDatabase::StickerDatabase(Path path) /* prepare the statements we're going to use */ - for (unsigned i = 0; i < ARRAY_SIZE(sticker_sql); ++i) { + for (unsigned i = 0; i < std::size(sticker_sql); ++i) { assert(sticker_sql[i] != nullptr); stmt[i] = Prepare(db, sticker_sql[i]); @@ -109,7 +110,7 @@ StickerDatabase::~StickerDatabase() noexcept { assert(db != nullptr); - for (unsigned i = 0; i < ARRAY_SIZE(stmt); ++i) { + for (unsigned i = 0; i < std::size(stmt); ++i) { assert(stmt[i] != nullptr); sqlite3_finalize(stmt[i]); |