mirror of
https://github.com/isar/rusqlite.git
synced 2024-11-22 06:10:35 +08:00
Add Statement::clear_bindings
This commit is contained in:
parent
aad182aff4
commit
5f851fb90f
@ -169,8 +169,10 @@ impl RawStatement {
|
||||
}
|
||||
|
||||
#[inline]
|
||||
pub fn clear_bindings(&self) -> c_int {
|
||||
unsafe { ffi::sqlite3_clear_bindings(self.ptr) }
|
||||
pub fn clear_bindings(&self) {
|
||||
unsafe {
|
||||
ffi::sqlite3_clear_bindings(self.ptr);
|
||||
} // rc is always SQLITE_OK
|
||||
}
|
||||
|
||||
#[inline]
|
||||
|
@ -870,6 +870,11 @@ impl Statement<'_> {
|
||||
mem::swap(&mut stmt, &mut self.stmt);
|
||||
stmt
|
||||
}
|
||||
|
||||
/// Reset all bindings
|
||||
pub fn clear_bindings(&mut self) {
|
||||
self.stmt.clear_bindings()
|
||||
}
|
||||
}
|
||||
|
||||
impl fmt::Debug for Statement<'_> {
|
||||
|
Loading…
Reference in New Issue
Block a user