Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -8,5 +8,6 @@ cmake-build-debug/
/compile
build/
build-xcode/
build-code-edit/
*.sqlite
*.db
2 changes: 1 addition & 1 deletion dev/conditions.h
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ namespace sqlite_orm {
* Collated something
*/
template<class T>
struct collate_t : public condition_t {
struct collate_t : condition_t {
T expr;
collate_argument argument;

Expand Down
3 changes: 0 additions & 3 deletions dev/function.h
Original file line number Diff line number Diff line change
Expand Up @@ -445,7 +445,6 @@ namespace sqlite_orm {
[[nodiscard]] consteval auto quote(F callable) const {
using Sig = function_signature_type_t<decltype(&F::operator())>;
// detect whether overloaded call operator can be picked using `Sig`
using call_operator_type = decltype(static_cast<Sig F::*>(&F::operator()));
return quoted_scalar_function<F, Sig, N>{this->cstr, std::move(callable)};
}

Expand All @@ -456,7 +455,6 @@ namespace sqlite_orm {
requires ((stateless<F> || std::copy_constructible<F>))
[[nodiscard]] consteval auto quote(F callable) const {
// detect whether overloaded call operator can be picked using `Sig`
using call_operator_type = decltype(static_cast<Sig F::*>(&F::operator()));
return quoted_scalar_function<F, Sig, N>{this->cstr, std::move(callable)};
}

Expand All @@ -477,7 +475,6 @@ namespace sqlite_orm {
requires ((stateless<F> || std::copy_constructible<F>))
[[nodiscard]] consteval auto quote(Args&&... constructorArgs) const {
// detect whether overloaded call operator can be picked using `Sig`
using call_operator_type = decltype(static_cast<Sig F::*>(&F::operator()));
return quoted_scalar_function<F, Sig, N>{this->cstr, std::forward<Args>(constructorArgs)...};
}
};
Expand Down
2 changes: 1 addition & 1 deletion dev/storage_base.h
Original file line number Diff line number Diff line change
Expand Up @@ -765,7 +765,7 @@ namespace sqlite_orm {
this->executor.perform_exec(
connection.get(),
ss.str(),
[](void* data, int argc, orm_gsl::zstring* argv, orm_gsl::zstring* /*columnName*/) -> int {
[](void* data, int /*argc*/, orm_gsl::zstring* argv, orm_gsl::zstring* /*columnName*/) -> int {
auto& objectNames_ = *(data_t*)data;
objectNames_.emplace_back(argv[0]);
return 0;
Expand Down
7 changes: 2 additions & 5 deletions include/sqlite_orm/sqlite_orm.h
Original file line number Diff line number Diff line change
Expand Up @@ -5159,7 +5159,7 @@ namespace sqlite_orm {
* Collated something
*/
template<class T>
struct collate_t : public condition_t {
struct collate_t : condition_t {
T expr;
collate_argument argument;

Expand Down Expand Up @@ -11515,7 +11515,6 @@ namespace sqlite_orm {
[[nodiscard]] consteval auto quote(F callable) const {
using Sig = function_signature_type_t<decltype(&F::operator())>;
// detect whether overloaded call operator can be picked using `Sig`
using call_operator_type = decltype(static_cast<Sig F::*>(&F::operator()));
return quoted_scalar_function<F, Sig, N>{this->cstr, std::move(callable)};
}

Expand All @@ -11526,7 +11525,6 @@ namespace sqlite_orm {
requires ((stateless<F> || std::copy_constructible<F>))
[[nodiscard]] consteval auto quote(F callable) const {
// detect whether overloaded call operator can be picked using `Sig`
using call_operator_type = decltype(static_cast<Sig F::*>(&F::operator()));
return quoted_scalar_function<F, Sig, N>{this->cstr, std::move(callable)};
}

Expand All @@ -11547,7 +11545,6 @@ namespace sqlite_orm {
requires ((stateless<F> || std::copy_constructible<F>))
[[nodiscard]] consteval auto quote(Args&&... constructorArgs) const {
// detect whether overloaded call operator can be picked using `Sig`
using call_operator_type = decltype(static_cast<Sig F::*>(&F::operator()));
return quoted_scalar_function<F, Sig, N>{this->cstr, std::forward<Args>(constructorArgs)...};
}
};
Expand Down Expand Up @@ -18813,7 +18810,7 @@ namespace sqlite_orm {
this->executor.perform_exec(
connection.get(),
ss.str(),
[](void* data, int argc, orm_gsl::zstring* argv, orm_gsl::zstring* /*columnName*/) -> int {
[](void* data, int /*argc*/, orm_gsl::zstring* argv, orm_gsl::zstring* /*columnName*/) -> int {
auto& objectNames_ = *(data_t*)data;
objectNames_.emplace_back(argv[0]);
return 0;
Expand Down
4 changes: 3 additions & 1 deletion tests/tests3.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -297,7 +297,8 @@ TEST_CASE("Blob") {
return data;
};

auto storage = make_storage("blob.db", make_table("blob", make_column("data", &BlobData::data)));
auto filename = "blob.db";
auto storage = make_storage(filename, make_table("blob", make_column("data", &BlobData::data)));
storage.sync_schema();
storage.remove_all<BlobData>();

Expand Down Expand Up @@ -340,6 +341,7 @@ TEST_CASE("Blob") {
storage.insert(BlobData{});

free(data);
std::remove(filename);
}

/**
Expand Down