mirror of
https://github.com/isar/rusqlite.git
synced 2025-03-31 19:12:58 +08:00
commit
844842d311
2
.github/workflows/main.yml
vendored
2
.github/workflows/main.yml
vendored
@ -202,7 +202,7 @@ jobs:
|
||||
- uses: actions/checkout@v4
|
||||
- uses: dtolnay/rust-toolchain@stable
|
||||
with:
|
||||
components: 'llvm-tools-preview'
|
||||
components: "llvm-tools-preview"
|
||||
- uses: taiki-e/install-action@main
|
||||
with:
|
||||
tool: grcov
|
||||
|
@ -21,7 +21,7 @@ pub fn SQLITE_TRANSIENT() -> sqlite3_destructor_type {
|
||||
Some(unsafe { mem::transmute::<isize, unsafe extern "C" fn(*mut std::ffi::c_void)>(-1_isize) })
|
||||
}
|
||||
|
||||
#[allow(clippy::all)]
|
||||
#[allow(dead_code, clippy::all)]
|
||||
mod bindings {
|
||||
include!(concat!(env!("OUT_DIR"), "/bindgen.rs"));
|
||||
}
|
||||
|
@ -372,7 +372,7 @@ impl Connection {
|
||||
/// The callback parameters are:
|
||||
///
|
||||
/// - the type of database update (`SQLITE_INSERT`, `SQLITE_UPDATE` or
|
||||
/// `SQLITE_DELETE`),
|
||||
/// `SQLITE_DELETE`),
|
||||
/// - the name of the database ("main", "temp", ...),
|
||||
/// - the name of the table that is updated,
|
||||
/// - the ROWID of the row that is updated.
|
||||
|
@ -128,7 +128,7 @@ impl Connection {
|
||||
/// - the name of the database ("main", "temp", ...),
|
||||
/// - the name of the table that is updated,
|
||||
/// - a variant of the PreUpdateCase enum which allows access to extra functions depending
|
||||
/// on whether it's an update, delete or insert.
|
||||
/// on whether it's an update, delete or insert.
|
||||
#[inline]
|
||||
pub fn preupdate_hook<F>(&self, hook: Option<F>)
|
||||
where
|
||||
@ -152,7 +152,7 @@ impl InnerConnection {
|
||||
/// let mut called = std::sync::atomic::AtomicBool::new(false);
|
||||
/// db.preupdate_hook(Some(|action, db: &str, tbl: &str, case: &PreUpdateCase| {
|
||||
/// called.store(true, std::sync::atomic::Ordering::Relaxed);
|
||||
/// }));
|
||||
/// }));
|
||||
/// }
|
||||
/// db.execute_batch("CREATE TABLE foo AS SELECT 1 AS bar;")
|
||||
/// }
|
||||
|
@ -7,6 +7,7 @@
|
||||
//! - Format 2: "YYYY-MM-DD HH:MM"
|
||||
//! - Format 5: "YYYY-MM-DDTHH:MM"
|
||||
//! - Format 8: "HH:MM"
|
||||
//!
|
||||
//! without an explicit second value will assume 0 seconds.
|
||||
//! Time String that contain an optional timezone without an explicit date are unsupported.
|
||||
//! All other assumptions described in [Time Values](https://sqlite.org/lang_datefunc.html#time_values) section are unsupported.
|
||||
|
@ -3,10 +3,10 @@
|
||||
//! Follow these steps to create your own virtual table:
|
||||
//! 1. Write implementation of [`VTab`] and [`VTabCursor`] traits.
|
||||
//! 2. Create an instance of the [`Module`] structure specialized for [`VTab`]
|
||||
//! impl. from step 1.
|
||||
//! impl. from step 1.
|
||||
//! 3. Register your [`Module`] structure using [`Connection::create_module`].
|
||||
//! 4. Run a `CREATE VIRTUAL TABLE` command that specifies the new module in the
|
||||
//! `USING` clause.
|
||||
//! `USING` clause.
|
||||
//!
|
||||
//! (See [SQLite doc](http://sqlite.org/vtab.html))
|
||||
use std::borrow::Cow::{self, Borrowed, Owned};
|
||||
|
Loading…
x
Reference in New Issue
Block a user