mirror of
https://github.com/isar/rusqlite.git
synced 2025-08-20 12:59:28 +08:00
clippy::semicolon_if_nothing_returned
This commit is contained in:
@@ -297,7 +297,7 @@ impl Backup<'_, '_> {
|
||||
loop {
|
||||
let r = self.step(pages_per_step)?;
|
||||
if let Some(progress) = progress {
|
||||
progress(self.progress())
|
||||
progress(self.progress());
|
||||
}
|
||||
match r {
|
||||
More | Busy | Locked => thread::sleep(pause_between_pages),
|
||||
|
@@ -46,13 +46,13 @@ impl Connection {
|
||||
/// can set the capacity manually using this method.
|
||||
#[inline]
|
||||
pub fn set_prepared_statement_cache_capacity(&self, capacity: usize) {
|
||||
self.cache.set_capacity(capacity)
|
||||
self.cache.set_capacity(capacity);
|
||||
}
|
||||
|
||||
/// Remove/finalize all prepared statements currently in the cache.
|
||||
#[inline]
|
||||
pub fn flush_prepared_statement_cache(&self) {
|
||||
self.cache.flush()
|
||||
self.cache.flush();
|
||||
}
|
||||
}
|
||||
|
||||
@@ -122,7 +122,7 @@ impl StatementCache {
|
||||
|
||||
#[inline]
|
||||
fn set_capacity(&self, capacity: usize) {
|
||||
self.0.borrow_mut().set_capacity(capacity)
|
||||
self.0.borrow_mut().set_capacity(capacity);
|
||||
}
|
||||
|
||||
// Search the cache for a prepared-statement object that implements `sql`.
|
||||
@@ -169,7 +169,7 @@ impl StatementCache {
|
||||
#[inline]
|
||||
fn flush(&self) {
|
||||
let mut cache = self.0.borrow_mut();
|
||||
cache.clear()
|
||||
cache.clear();
|
||||
}
|
||||
}
|
||||
|
||||
|
@@ -58,7 +58,7 @@ pub(super) unsafe fn set_result(ctx: *mut sqlite3_context, result: &ToSqlOutput<
|
||||
if length > c_int::max_value() as usize {
|
||||
ffi::sqlite3_result_error_toobig(ctx);
|
||||
} else if length == 0 {
|
||||
ffi::sqlite3_result_zeroblob(ctx, 0)
|
||||
ffi::sqlite3_result_zeroblob(ctx, 0);
|
||||
} else {
|
||||
ffi::sqlite3_result_blob(
|
||||
ctx,
|
||||
|
@@ -402,7 +402,7 @@ impl Connection {
|
||||
where
|
||||
F: for<'r> FnMut(AuthContext<'r>) -> Authorization + Send + RefUnwindSafe + 'static,
|
||||
{
|
||||
self.db.borrow_mut().authorizer(hook)
|
||||
self.db.borrow_mut().authorizer(hook);
|
||||
}
|
||||
}
|
||||
|
||||
|
@@ -143,7 +143,7 @@ impl Sql {
|
||||
if ch == quote {
|
||||
self.buf.push(ch);
|
||||
}
|
||||
self.buf.push(ch)
|
||||
self.buf.push(ch);
|
||||
}
|
||||
self.buf.push(quote);
|
||||
}
|
||||
|
@@ -178,7 +178,7 @@ impl Transaction<'_> {
|
||||
/// dropped.
|
||||
#[inline]
|
||||
pub fn set_drop_behavior(&mut self, drop_behavior: DropBehavior) {
|
||||
self.drop_behavior = drop_behavior
|
||||
self.drop_behavior = drop_behavior;
|
||||
}
|
||||
|
||||
/// A convenience method which consumes and commits a transaction.
|
||||
@@ -306,7 +306,7 @@ impl Savepoint<'_> {
|
||||
/// dropped.
|
||||
#[inline]
|
||||
pub fn set_drop_behavior(&mut self, drop_behavior: DropBehavior) {
|
||||
self.drop_behavior = drop_behavior
|
||||
self.drop_behavior = drop_behavior;
|
||||
}
|
||||
|
||||
/// A convenience method which consumes and commits a savepoint.
|
||||
|
Reference in New Issue
Block a user