Skip to content

Commit c0c009a

Browse files
committed
review fixed
1 parent 61eb04b commit c0c009a

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

src/node_sqlite.h

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,8 @@ inline constexpr std::array<LimitInfo, 11> kLimitMapping = {{
4040
}};
4141

4242
// Static assertions to ensure limit mapping is complete and valid
43-
static_assert(kLimitMapping.size() == SQLITE_LIMIT_TRIGGER_DEPTH + 1,
43+
static_assert(kLimitMapping.size() ==
44+
static_cast<size_t>(SQLITE_LIMIT_TRIGGER_DEPTH + 1),
4445
"kLimitMapping must cover all SQLite limits");
4546

4647
constexpr bool CheckLimitBounds() {
@@ -113,7 +114,7 @@ class DatabaseOpenConfiguration {
113114
initial_limits_[sqlite_limit_id] = value;
114115
}
115116

116-
inline const std::array<std::optional<int>, SQLITE_LIMIT_TRIGGER_DEPTH + 1>&
117+
inline const std::array<std::optional<int>, kLimitMapping.size()>&
117118
initial_limits() const {
118119
return initial_limits_;
119120
}
@@ -129,8 +130,7 @@ class DatabaseOpenConfiguration {
129130
bool allow_bare_named_params_ = true;
130131
bool allow_unknown_named_params_ = false;
131132
bool defensive_ = true;
132-
std::array<std::optional<int>, SQLITE_LIMIT_TRIGGER_DEPTH + 1>
133-
initial_limits_{};
133+
std::array<std::optional<int>, kLimitMapping.size()> initial_limits_{};
134134
};
135135

136136
class DatabaseSync;

0 commit comments

Comments
 (0)