David Tolnay
bd588db067
Release 1.0.121
2021-01-23 13:17:08 -08:00
David Tolnay
34f4b68f77
Fix unneeded clone from PR #1917
2021-01-23 12:40:00 -08:00
David Tolnay
60e08f9545
Format PR #1917 with rustfmt 1.4.32
2021-01-23 12:39:59 -08:00
David Tolnay
ba46f45dc5
Merge pull request 1917 from Mingun/borrow-identifier
2021-01-23 12:39:28 -08:00
David Tolnay
398fba9b1e
Release 1.0.120
2021-01-18 22:55:13 -08:00
David Tolnay
4c89cf89fd
Release 1.0.119
2021-01-11 12:13:57 -08:00
David Tolnay
dd1f4b483e
Make it clearer that the private implementation details are private
...
Both of these modules are doc(hidden) and commented "Not public API",
but incorrect downstream code sometimes still references them. Naming
the module __private will make it more likely to be noticed in code
review.
2021-01-08 19:55:31 -08:00
David Tolnay
e797431268
Release 1.0.118
2020-12-05 13:45:47 -08:00
David Tolnay
0d5b6c180c
Resolve ptr_eq clippy lint
...
error: use `std::ptr::eq` when comparing raw pointers
--> serde_derive/src/de.rs:362:12
|
362 | if field as *const Field == transparent_field as *const Field {
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: try: `std::ptr::eq(field, transparent_field)`
|
note: the lint level is defined here
--> serde_derive/src/lib.rs:18:9
|
18 | #![deny(clippy::all, clippy::pedantic)]
| ^^^^^^^^^^^
= note: `#[deny(clippy::ptr_eq)]` implied by `#[deny(clippy::all)]`
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#ptr_eq
2020-10-27 19:18:29 -07:00
Taiki Endo
a227a87865
Collect lifetimes inside macro invocations
2020-10-24 05:29:47 +09:00
Mingun
7a7a182ab6
Allow borrow for field identifiers
2020-10-23 19:03:18 +05:00
Mingun
104ad9a7dd
Allow to define custom expectation message for type with #[serde(expecting = "...")]
...
Closes #1883
2020-10-23 01:23:01 +05:00
Mingun
0737474640
Allow field identifiers be any numbers if #[serde(other)]
is used
...
Thus behavior synchronized between string/bytes identifiers and numeric identifiers
2020-10-22 16:35:28 +05:00
David Tolnay
fc3f104c4a
Release 1.0.117
2020-10-15 09:49:03 -07:00
David Tolnay
be7d0e7eb2
Ignore map_err_ignore Clippy pedantic lint
2020-09-25 21:55:59 -04:00
David Tolnay
b539cb45d7
Release 1.0.116
2020-09-11 11:56:19 -07:00
David Tolnay
2ef60b62ac
Release 1.0.115
2020-08-10 15:51:19 -07:00
David Tolnay
53b9871b17
Quote no longer requires high recursion
2020-07-16 10:49:16 -07:00
David Tolnay
f8787c3ca8
Suppress match_like_matches_macro clippy lint
2020-07-14 18:57:26 -07:00
David Tolnay
3022064f84
Suppress option_if_let_else clippy pedantic lint
2020-07-14 18:57:24 -07:00
David Tolnay
9c6f0c3a0e
Release 1.0.114
2020-06-21 17:31:02 -07:00
David Tolnay
a9f8ea0a1e
Simplify search for packed repr attr
2020-06-21 17:22:07 -07:00
Tanner Rogalsky
1cd10a7d09
Improved packed repr matching.
2020-06-21 16:46:27 -07:00
David Tolnay
7350b58f5c
Release 1.0.113
2020-06-19 13:31:38 -07:00
David Tolnay
7351e0e55a
Link to feature announcements where available
2020-06-19 13:30:14 -07:00
Taiki Endo
a50e1c20e9
Use underscore consts on Rust 1.37+
2020-06-19 15:55:43 +09:00
David Tolnay
f3520e526b
Release 1.0.112
2020-06-14 11:16:04 -07:00
David Tolnay
95b1a5d3d9
Ignore unnested_or_patterns suggesting unstable code
...
Clippy bug: https://github.com/rust-lang/rust-clippy/issues/5704
2020-06-10 19:41:16 -07:00
David Tolnay
0856a2c101
No need to specify Cargo.toml in package.include
...
Cargo.toml is always included in the published crate.
2020-06-10 01:21:19 -07:00
David Tolnay
9f331cc257
Release 1.0.111
2020-05-29 18:53:07 -07:00
David Tolnay
c45a809d5c
Look inside of None-delimited groups when examining types
2020-05-29 17:58:34 -07:00
David Tolnay
078b171c1b
Release 1.0.110
2020-05-09 23:06:56 -07:00
David Tolnay
da8d6f678e
Simplify finding of repr(packed) attributes
2020-05-09 23:02:49 -07:00
David Tolnay
548eb8f667
Format PR 1791 with rustfmt
2020-05-09 22:54:42 -07:00
David Tolnay
1fe39043ee
Simplify access of packed struct fields in derived Serialize impls
2020-05-09 22:53:38 -07:00
alvardes
9f47c47cad
Add support for packed structs.
2020-05-09 22:45:44 -07:00
David Tolnay
dda070f45c
Fix borrow error on pre-NLL compilers
...
error[E0506]: cannot assign to `missing_content` because it is borrowed
--> serde_derive/src/de.rs:1414:9
|
1388 | .filter_map(|(i, variant)| {
| -------------- borrow of `missing_content` occurs here
...
1414 | / missing_content = quote! {
1415 | | match __field {
1416 | | #(#missing_content_arms)*
1417 | | #missing_content_fallthrough
1418 | | }
1419 | | };
| |_________^ assignment to borrowed `missing_content` occurs here
error[E0502]: cannot borrow `missing_content_fallthrough` as immutable because it is also borrowed as mutable
--> serde_derive/src/de.rs:1414:27
|
1388 | .filter_map(|(i, variant)| {
| -------------- mutable borrow occurs here
...
1404 | missing_content_fallthrough = quote!(_ => #missing_content);
| --------------------------- previous borrow occurs due to use of `missing_content_fallthrough` in closure
...
1414 | missing_content = quote! {
| ___________________________^
1415 | | match __field {
1416 | | #(#missing_content_arms)*
1417 | | #missing_content_fallthrough
1418 | | }
1419 | | };
| |_________^ immutable borrow occurs here
...
1622 | }
| - mutable borrow ends here
|
= note: this error originates in a macro outside of the current crate (in Nightly builds, run with -Z external-macro-backtrace for more info)
2020-05-09 22:37:31 -07:00
David Tolnay
b97a183e82
Release 1.0.109
2020-05-09 21:00:51 -07:00
David Tolnay
9433004307
Omit missing content match if not needed
2020-05-09 20:59:01 -07:00
David Tolnay
9476838264
Omit missing content fallthrough arm if not needed
2020-05-09 20:59:00 -07:00
asdsad
172edc4cf4
Allow optional content field for adjacently tagged newtype variants
...
* Deserialize adjacently tagged newtype variants with optional content as None instead of erroring when content field is missing
* refactor to remove duplicate code and remove panic
2020-05-09 20:58:28 -07:00
David Tolnay
ea2789df0f
Release 1.0.108
2020-05-09 17:53:23 -07:00
David Tolnay
f63acb52dc
Release 1.0.107
2020-05-08 15:45:36 -07:00
David Tolnay
63809e69c7
Fix indexing bug when skip
and other
are combined
2020-05-08 15:39:07 -07:00
David Tolnay
60522937af
Remove CI badge from Cargo.toml
...
Support for badges has been deprecated by crates.io.
2020-05-01 21:11:02 -07:00
David Tolnay
b6def5300a
Resolve redundant_field_names lint in serde_derive
2020-04-05 21:07:52 -07:00
David Tolnay
1b35c9e27e
Update serde_derive to tool attrs
2020-04-05 21:00:58 -07:00
David Tolnay
d1564525ad
Release 1.0.106
2020-04-03 14:26:42 -07:00
robo9k
a135199ab1
Hide generated dummy const in rustdoc
2020-04-03 22:21:38 +02:00
David Tolnay
69653a762d
Release 1.0.105
2020-03-18 11:42:51 -07:00