Thom Chiovoloni
cdce75328e
Fix build on some older versions of Rust
2021-05-08 22:56:19 -07:00
gwenn
c4b398f468
Doctest column name reference ( #918 )
...
* Doctest column name reference
* Document rusqlite assumption on column name reference
And move doctest as a test.
* Document when columns metadata should be extracted.
* Rustfmt doc (wrap_comments)
2021-04-03 11:03:50 +02:00
Nick Hynes
ecbc0aa767
Leniently parse rfc3339 timezones ( #928 )
2021-04-03 10:56:11 +02:00
gwenn
91d6ce7a52
Fix unstable tests when machine is slow
2021-01-30 12:55:00 +01:00
gwenn
4f175d5748
Fix DateTime format
2021-01-29 22:03:50 +01:00
gwenn
afcdc2b43a
Use most concise syntax for params
2021-01-19 21:16:08 +01:00
gwenn
3aeb5d7e08
Remove obsolete doc section
...
`FromSql` / `ToSql` are now implemented for i64 and usize
2020-11-22 09:37:52 +01:00
gwenn
6fae5d6641
Add/fix rustdoc links
2020-11-22 09:34:03 +01:00
gwenn
549ceb59e2
Try to fix CI build
2020-11-05 22:21:02 +01:00
gwenn
da94f8eba6
Make tests return Result
2020-11-05 22:14:00 +01:00
Thom Chiovoloni
65c38bf813
Add #[inline]
and #[cold]
in far more places
2020-11-04 07:59:23 -08:00
Thom Chiovoloni
22121772a2
Deprecate NO_PARAMS in favor of passing an empty array
2020-11-03 19:09:19 -08:00
Thom Chiovoloni
032aea73b8
Overhaul query API, removing the need for the _named
variants of all functions, and rusqlite::NO_PARAMS
2020-11-03 19:09:19 -08:00
gwenn
b448d95510
Merge remote-tracking branch 'upstream/master' into progress_handler
2020-10-28 21:21:19 +01:00
gwenn
76ad2bf19c
Rustfmt
2020-10-28 21:12:29 +01:00
Tim Hutt
b0ade73f43
Add ToSql implementations for u64 and usize
2020-10-26 23:28:25 -07:00
Tim Hutt
8841187717
Silence clippy
2020-10-24 09:52:05 -07:00
Tim Hutt
f264873999
Cargo format
2020-10-24 09:52:05 -07:00
Tim Hutt
ebcec59969
Implement From/ToSql for more types
...
This implements `FromSql` for `u64`, `usize` and `f32`, and `ToSql` for `f32`.
I also updated the documentation to describe how it currently works, and changed the implementation to use `try_from` for integral casts rather rather than custom code.
Test added.
2020-10-24 09:52:05 -07:00
gwenn
799b5d3f7b
Rustfmt
2020-10-04 07:39:35 +02:00
gwenn
d2dcc2d987
Fix clippy warning
2020-10-04 07:38:52 +02:00
gwenn
2a7b11320f
Fix clippy warnings
2020-08-17 20:07:56 +02:00
Nikhil Benesch
b83d22e2b7
Upgrade to time v0.2 and put it behind a feature flag
...
This also removes the usage of time in the crate's top-level
documentation example, as was done for the README in #625 .
Fix #653 .
2020-07-24 11:28:19 -07:00
gwenn
4114c94585
Clippy
2020-06-26 19:22:20 +02:00
gwenn
76fc22c653
Fix missing docs
2020-05-21 00:48:06 -07:00
Thom Chiovoloni
38aea89809
Remove implementations of std::error::Error::description
2020-04-12 12:06:53 -07:00
Thom Chiovoloni
5a8108bd86
Implement source
and not cause
for FromSqlError
2020-04-12 12:06:53 -07:00
gwenn
4dbfdc85fe
Fix ValueRef::from_value
...
Handle text with internal nuls (#657 )
2020-04-11 22:18:22 -07:00
Thom Chiovoloni
76336369ed
Fix regression with <Cow<'_, _> as ToSql> ( #681 )
2020-04-06 17:00:15 -07:00
Thom Chiovoloni
6f6f7ffd9f
Add #[non_exhaustive]
to enums that might get new variants. ( #673 )
...
This just using them in patterns without a catchall. I left things alone
that seem very unlikely to change (`Value`, `ValueRef`, `DatabaseName`,
etc...). This might help reduce the number of breaking changes we need
(rusqlite is still pre-1.0 so it doesn't really matter that much, but
breaking changes complicate the story around when we can cut releases).
2020-04-06 12:01:39 -07:00
Thom Chiovoloni
6617db59fb
Document which features are required, and add vtab usage examples ( #669 )
2020-04-05 22:15:27 -07:00
zero-systems
2a04f06a3a
Relaxed Sized bound on Box/Rc/Arc/Cow for ToSql
...
* Fix Box<T> for unsized
* refactoring
* Add more tests
* ?Sized for Cow, Rc, Arc too
2020-03-31 20:52:34 -07:00
zero-systems
761df93a83
Impls of ToSql for different generic types (Box, Cow, Rc, Arc). ( #660 )
...
* Impl ToSql for Box<str>
* Add generic impls for Cow, Box, Rc, Arc. Remove impl for Box<str>
* Remove impl of ToSql for Cow<'_, str>
* Add missing as_ref
Co-authored-by: Øsystems <>
2020-03-28 09:53:03 -07:00
gwenn
922228f604
Fix clippy warnings
2020-02-09 11:48:08 +01:00
gwenn
adb904650d
Fix warnings related to deprecated Error::description
2020-01-26 16:57:58 +01:00
Thom Chiovoloni
585797b4d6
Add FromSql for Box<str>, Rc<str> and Arc<str>
2020-01-14 08:26:16 -08:00
gwenn
8302a50fb8
Fix clippy warnings
2019-11-03 11:19:07 +01:00
gwenn
0cf9ef8514
Fix some clippy warnings
2019-10-13 13:08:33 +02:00
Will Dowd
49f48a5c56
Parse Option<T> into Value/ValueRef where applicable
2019-09-27 16:02:37 -04:00
gwenn
08e32444c9
Cleanup use statements
2019-08-17 08:18:37 +02:00
gwenn
701389605d
Do not assume sqlite3_column_text
is valid UTF-8
...
Fix impact on features
2019-07-24 20:46:53 +02:00
gwenn
f0ae7b6e9b
Do not assume sqlite3_column_text
is valid UTF-8.
...
Fix Statement::value_ref
2019-07-24 20:08:31 +02:00
Thom Chiovoloni
4356f5a176
Include the name of the column in InvalidColumnType errors
2019-06-25 12:20:11 -07:00
gwenn
860cf69660
[ci skip] Fix rustdoc
...
"impl ToSql for NaiveDateTime" documentation is slightly inconsistent
with behavior #519
2019-05-11 13:05:15 +02:00
Simon Bernier St-Pierre
c42175a424
add support for Uuid
2019-04-08 14:19:42 -04:00
Thom Chiovoloni
d8074b1ece
impl ToSql for Box<dyn ToSql>. Fixes #500
2019-03-27 19:36:11 -07:00
gwenn
80205da623
Rustfmt + clippy
2019-03-21 19:13:55 +01:00
gwenn
ceb1ce4a55
Rustfmt
2019-03-19 20:45:04 +01:00
gwenn
ac0baecfe2
Merge pull request #478 from gwenn/fallible-iterator
...
Make `Rows` implement `FallibleStreamingIterator`
2019-03-10 13:13:34 +01:00
gwenn
59a44cfae5
Merge remote-tracking branch 'jgallagher/master' into fallible-iterator
2019-03-10 11:12:14 +01:00