[core] Fix performance-noexcept-move-constructor errors
As reported by clang-tidy-8.
This commit is contained in:
@@ -79,9 +79,9 @@ public:
|
||||
static mapbox::util::variant<Database, Exception> tryOpen(const std::string &filename, int flags = 0);
|
||||
static Database open(const std::string &filename, int flags = 0);
|
||||
|
||||
Database(Database &&);
|
||||
Database(Database&&) noexcept;
|
||||
~Database();
|
||||
Database &operator=(Database &&);
|
||||
Database& operator=(Database&&) noexcept;
|
||||
|
||||
void setBusyTimeout(std::chrono::milliseconds);
|
||||
void exec(const std::string &sql);
|
||||
|
||||
@@ -144,10 +144,9 @@ Database::Database(std::unique_ptr<DatabaseImpl> impl_)
|
||||
: impl(std::move(impl_))
|
||||
{}
|
||||
|
||||
Database::Database(Database &&other)
|
||||
: impl(std::move(other.impl)) {}
|
||||
Database::Database(Database&& other) noexcept : impl(std::move(other.impl)) {}
|
||||
|
||||
Database &Database::operator=(Database &&other) {
|
||||
Database& Database::operator=(Database&& other) noexcept {
|
||||
std::swap(impl, other.impl);
|
||||
return *this;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user