mirror of
				https://github.com/isar/rusqlite.git
				synced 2025-10-31 22:08:55 +08:00 
			
		
		
		
	fix several typos
This commit is contained in:
		
				
					committed by
					
						 Thom Chiovoloni
						Thom Chiovoloni
					
				
			
			
				
	
			
			
			
						parent
						
							b8b1138fcf
						
					
				
				
					commit
					c33d6bfad3
				
			| @@ -117,7 +117,7 @@ lazy_static = "1.4" | ||||
| regex = "1.3" | ||||
| uuid = { version = "0.8", features = ["v4"] } | ||||
| unicase = "2.6.0" | ||||
| # Use `bencher` over criterion becasue it builds much faster and we don't have | ||||
| # Use `bencher` over criterion because it builds much faster and we don't have | ||||
| # many benchmarks | ||||
| bencher = "0.1" | ||||
|  | ||||
|   | ||||
| @@ -96,7 +96,7 @@ mod build_bundled { | ||||
|  | ||||
|         // Older versions of visual studio don't support c99 (including isnan), which | ||||
|         // causes a build failure when the linker fails to find the `isnan` | ||||
|         // function. `sqlite` provides its own implmentation, using the fact | ||||
|         // function. `sqlite` provides its own implementation, using the fact | ||||
|         // that x != x when x is NaN. | ||||
|         // | ||||
|         // There may be other platforms that don't support `isnan`, they should be | ||||
|   | ||||
| @@ -143,7 +143,7 @@ pub enum StepResult { | ||||
|     /// backed up. | ||||
|     More, | ||||
|  | ||||
|     /// The step failed because appropriate locks could not be aquired. This is | ||||
|     /// The step failed because appropriate locks could not be acquired. This is | ||||
|     /// not a fatal error - the step can be retried. | ||||
|     Busy, | ||||
|  | ||||
|   | ||||
| @@ -54,11 +54,11 @@ | ||||
| //!    filled in order for the call to be considered a success. | ||||
| //! | ||||
| //!    The "exact" functions require the provided buffer be entirely filled, or | ||||
| //!    they return an error, wheras the "inexact" functions read as much out of | ||||
| //!    they return an error, whereas the "inexact" functions read as much out of | ||||
| //!    the blob as is available, and return how much they were able to read. | ||||
| //! | ||||
| //!    The inexact functions are preferrable if you do not know the size of the | ||||
| //!    blob already, and the exact functions are preferrable if you do. | ||||
| //!    The inexact functions are preferable if you do not know the size of the | ||||
| //!    blob already, and the exact functions are preferable if you do. | ||||
| //! | ||||
| //! ### Comparison to using the `std::io` traits: | ||||
| //! | ||||
|   | ||||
| @@ -4,7 +4,7 @@ | ||||
| //! | ||||
| //! Adding a `regexp` function to a connection in which compiled regular | ||||
| //! expressions are cached in a `HashMap`. For an alternative implementation | ||||
| //! that uses SQLite's [Function Auxilliary Data](https://www.sqlite.org/c3ref/get_auxdata.html) interface | ||||
| //! that uses SQLite's [Function Auxiliary Data](https://www.sqlite.org/c3ref/get_auxdata.html) interface | ||||
| //! to avoid recompiling regular expressions, see the unit tests for this | ||||
| //! module. | ||||
| //! | ||||
| @@ -167,7 +167,7 @@ impl Context<'_> { | ||||
|         unsafe { ValueRef::from_value(arg) } | ||||
|     } | ||||
|  | ||||
|     /// Fetch or insert the auxilliary data associated with a particular | ||||
|     /// Fetch or insert the auxiliary data associated with a particular | ||||
|     /// parameter. This is intended to be an easier-to-use way of fetching it | ||||
|     /// compared to calling [`get_aux`](Context::get_aux) and | ||||
|     /// [`set_aux`](Context::set_aux) separately. | ||||
| @@ -191,7 +191,7 @@ impl Context<'_> { | ||||
|         } | ||||
|     } | ||||
|  | ||||
|     /// Sets the auxilliary data associated with a particular parameter. See | ||||
|     /// Sets the auxiliary data associated with a particular parameter. See | ||||
|     /// `https://www.sqlite.org/c3ref/get_auxdata.html` for a discussion of | ||||
|     /// this feature, or the unit tests of this module for an example. | ||||
|     pub fn set_aux<T: Send + Sync + 'static>(&self, arg: c_int, value: T) -> Result<Arc<T>> { | ||||
| @@ -210,7 +210,7 @@ impl Context<'_> { | ||||
|         Ok(orig) | ||||
|     } | ||||
|  | ||||
|     /// Gets the auxilliary data that was associated with a given parameter via | ||||
|     /// Gets the auxiliary data that was associated with a given parameter via | ||||
|     /// [`set_aux`](Context::set_aux). Returns `Ok(None)` if no data has been | ||||
|     /// associated, and Ok(Some(v)) if it has. Returns an error if the | ||||
|     /// requested type does not match. | ||||
| @@ -839,7 +839,7 @@ mod test { | ||||
|         Ok(()) | ||||
|     } | ||||
|  | ||||
|     // This implementation of a regexp scalar function uses SQLite's auxilliary data | ||||
|     // This implementation of a regexp scalar function uses SQLite's auxiliary data | ||||
|     // (https://www.sqlite.org/c3ref/get_auxdata.html) to avoid recompiling the regular | ||||
|     // expression multiple times within one query. | ||||
|     fn regexp_with_auxilliary(ctx: &Context<'_>) -> Result<bool> { | ||||
|   | ||||
| @@ -974,7 +974,7 @@ impl Default for OpenFlags { | ||||
| /// | ||||
| /// This function is unsafe because if you call it and SQLite has actually been | ||||
| /// configured to run in single-thread mode, | ||||
| /// you may enounter memory errors or data corruption or any number of terrible | ||||
| /// you may encounter memory errors or data corruption or any number of terrible | ||||
| /// things that should not be possible when you're using Rust. | ||||
| pub unsafe fn bypass_sqlite_initialization() { | ||||
|     BYPASS_SQLITE_INIT.store(true, Ordering::Relaxed); | ||||
|   | ||||
| @@ -198,7 +198,7 @@ impl Params for &[(&str, &dyn ToSql)] { | ||||
|  | ||||
| macro_rules! impl_for_array_ref { | ||||
|     ($($N:literal)+) => {$( | ||||
|         // These are already generic, and theres a shitload of them, so lets | ||||
|         // These are already generic, and there's a shedload of them, so lets | ||||
|         // avoid the compile time hit from making them all inline for now. | ||||
|         impl<T: ToSql + ?Sized> Sealed for &[&T; $N] {} | ||||
|         impl<T: ToSql + ?Sized> Params for &[&T; $N] { | ||||
|   | ||||
| @@ -105,7 +105,7 @@ impl Drop for Rows<'_> { | ||||
|     } | ||||
| } | ||||
|  | ||||
| /// `F` is used to tranform the _streaming_ iterator into a _fallible_ iterator. | ||||
| /// `F` is used to transform the _streaming_ iterator into a _fallible_ iterator. | ||||
| #[must_use = "iterators are lazy and do nothing unless consumed"] | ||||
| pub struct Map<'stmt, F> { | ||||
|     rows: Rows<'stmt>, | ||||
| @@ -130,7 +130,7 @@ where | ||||
|  | ||||
| /// An iterator over the mapped resulting rows of a query. | ||||
| /// | ||||
| /// `F` is used to tranform the _streaming_ iterator into a _standard_ iterator. | ||||
| /// `F` is used to transform the _streaming_ iterator into a _standard_ iterator. | ||||
| #[must_use = "iterators are lazy and do nothing unless consumed"] | ||||
| pub struct MappedRows<'stmt, F> { | ||||
|     rows: Rows<'stmt>, | ||||
|   | ||||
| @@ -247,7 +247,7 @@ impl Statement<'_> { | ||||
|     /// Executes the prepared statement and maps a function over the resulting | ||||
|     /// rows, returning an iterator over the mapped function results. | ||||
|     /// | ||||
|     /// `f` is used to tranform the _streaming_ iterator into a _standard_ | ||||
|     /// `f` is used to transform the _streaming_ iterator into a _standard_ | ||||
|     /// iterator. | ||||
|     /// | ||||
|     /// This is equivalent to `stmt.query(params)?.mapped(f)`. | ||||
| @@ -310,7 +310,7 @@ impl Statement<'_> { | ||||
|     /// most-recently bound value from a previous call to `query_named`, | ||||
|     /// or `NULL` if they have never been bound. | ||||
|     /// | ||||
|     /// `f` is used to tranform the _streaming_ iterator into a _standard_ | ||||
|     /// `f` is used to transform the _streaming_ iterator into a _standard_ | ||||
|     /// iterator. | ||||
|     /// | ||||
|     /// ## Failure | ||||
|   | ||||
| @@ -1,7 +1,7 @@ | ||||
| //! `feature = "vtab"` Create virtual tables. | ||||
| //! | ||||
| //! Follow these steps to create your own virtual table: | ||||
| //! 1. Write implemenation of [`VTab`] and [`VTabCursor`] traits. | ||||
| //! 1. Write implementation of [`VTab`] and [`VTabCursor`] traits. | ||||
| //! 2. Create an instance of the [`Module`] structure specialized for [`VTab`] | ||||
| //! impl. from step 1. | ||||
| //! 3. Register your [`Module`] structure using [`Connection::create_module`]. | ||||
| @@ -680,7 +680,7 @@ impl InnerConnection { | ||||
|     } | ||||
| } | ||||
|  | ||||
| /// `feature = "vtab"` Escape double-quote (`"`) character occurences by | ||||
| /// `feature = "vtab"` Escape double-quote (`"`) character occurrences by | ||||
| /// doubling them (`""`). | ||||
| pub fn escape_double_quote(identifier: &str) -> Cow<'_, str> { | ||||
|     if identifier.contains('"') { | ||||
|   | ||||
| @@ -162,7 +162,7 @@ struct SeriesTabCursor<'vtab> { | ||||
|     row_id: i64, | ||||
|     /// Current value ("value") | ||||
|     value: i64, | ||||
|     /// Mimimum value ("start") | ||||
|     /// Minimum value ("start") | ||||
|     min_value: i64, | ||||
|     /// Maximum value ("stop") | ||||
|     max_value: i64, | ||||
|   | ||||
		Reference in New Issue
	
	Block a user