diff --git a/include/SQLiteCpp/Statement.h b/include/SQLiteCpp/Statement.h index 5f1e3903..8eade34f 100644 --- a/include/SQLiteCpp/Statement.h +++ b/include/SQLiteCpp/Statement.h @@ -178,6 +178,11 @@ class SQLITECPP_API Statement * @warning Uses the SQLITE_STATIC flag, avoiding a copy of the data. The string must remains unchanged while executing the statement. */ void bindNoCopy(const int aIndex, const void* apValue, const int aSize); + /** + * @brief Deleted, because the value's lifetime could not be guaranteed. Use bind(). + */ + void bindNoCopy(const int aIndex, std::string&& aValue) = delete; + /** * @brief Bind a NULL value to a parameter "?", "?NNN", ":VVV", "@VVV" or "$VVV" in the SQL prepared statement (aIndex >= 1) * @@ -271,6 +276,10 @@ class SQLITECPP_API Statement { bindNoCopy(getIndex(apName), apValue, aSize); } + /** + * @brief Deleted, because the value's lifetime could not be guaranteed. Use bind(). + */ + void bindNoCopy(const char* apName, std::string&& aValue) = delete; /** * @brief Bind a NULL value to a named parameter "?NNN", ":VVV", "@VVV" or "$VVV" in the SQL prepared statement (aIndex >= 1) * @@ -368,6 +377,10 @@ class SQLITECPP_API Statement { bindNoCopy(aName.c_str(), apValue, aSize); } + /** + * @brief Deleted, because the value's lifetime could not be guaranteed. Use bind(). + */ + void bindNoCopy(const std::string& aName, std::string&& aValue) = delete; /** * @brief Bind a NULL value to a named parameter "?NNN", ":VVV", "@VVV" or "$VVV" in the SQL prepared statement (aIndex >= 1) *