Skip to content

Commit 89220f7

Browse files
committed
Fixed the major issue with committing here
Thank you Bennet <3
1 parent d6f4070 commit 89220f7

File tree

1 file changed

+7
-2
lines changed

1 file changed

+7
-2
lines changed

hdr/sqlite_modern_cpp/type_wrapper.h

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -166,6 +166,12 @@ namespace sqlite {
166166
inline void store_result_in_db(sqlite3_context* db, std::nullptr_t) {
167167
sqlite3_result_null(db);
168168
}
169+
inline int bind_col_in_db(sqlite3_stmt* stmt, int inx, std::monostate) {
170+
return sqlite3_bind_null(stmt, inx);
171+
}
172+
inline void store_result_in_db(sqlite3_context* db, std::monostate) {
173+
sqlite3_result_null(db);
174+
}
169175

170176
// str_ref
171177
template<>
@@ -289,7 +295,6 @@ namespace sqlite {
289295
}
290296
return std::make_unique<T>(get_val_from_db(value, result_type<T>()));
291297
}
292-
293298
// std::optional support for NULL values
294299
#ifdef MODERN_SQLITE_STD_OPTIONAL_SUPPORT
295300
#ifdef MODERN_SQLITE_EXPERIMENTAL_OPTIONAL_SUPPORT
@@ -351,7 +356,7 @@ namespace sqlite {
351356

352357
template<int Type, class ...Options>
353358
struct has_sqlite_type<std::variant<Options...>, Type, void> : std::disjunction<detail::tag_trait<Options, has_sqlite_type<Options, Type>>...> {};
354-
359+
355360
namespace detail {
356361
template<int Type, typename ...Options, typename Callback, typename first_compatible = has_sqlite_type<std::variant<Options...>, Type>>
357362
inline std::variant<Options...> variant_select_type(Callback &&callback) {

0 commit comments

Comments
 (0)