Adam Crume
05e931b9a5
Update tests and use quote! macro
2018-06-02 21:11:42 -07:00
David Tolnay
b13875dd97
Add compile-fail tests for transparent error messages
2018-05-20 21:55:50 -07:00
David Tolnay
7e3efaf6c5
Improve error when a 'de lifetime parameter already exists
2018-05-07 21:15:44 -07:00
David Tolnay
0025ef9aba
Detect deserialize on a struct ending in dynamically sized slice
2018-05-07 11:52:59 -07:00
David Tolnay
2009b4da5f
Remove old flatten in enum compile-fail test
2018-05-06 21:26:40 -07:00
David Tolnay
860241aa88
Merge pull request #1205 from mitsuhiko/bugfix/tuple-struct-flatten
...
Produce error message for use of flatten in tuple structs
2018-04-02 07:09:39 +02:00
Armin Ronacher
77376f39ea
Produce error message for use of flatten in tuple structs
2018-04-01 22:11:21 +02:00
Armin Ronacher
302fac91a3
Produce error message for use of flatten within struct variant
2018-04-01 22:01:24 +02:00
David Tolnay
5c9c97c0ce
Remove test that fails to parse flatten attribute
2018-03-25 12:33:50 +02:00
Armin Ronacher
3d647f4063
Fixed a compilefail test for flatten on enums
2018-03-20 23:26:22 +01:00
Armin Ronacher
99614c7266
Added flatten on enum compile fail test
2018-03-20 22:15:47 +01:00
Armin Ronacher
bb2ecb3bc4
Added compilefail tests for flatten conflicts
2018-03-20 22:04:12 +01:00
Armin Ronacher
b4ef7ac323
Updated tests for flatten
2018-03-16 23:05:48 +01:00
Armin Ronacher
77b07f3fbf
Added tests for unknown_fields_into
2018-03-16 23:05:22 +01:00
David Tolnay
f288a41768
Test the new errors on conflicting enum tags
2018-03-08 09:31:25 -08:00
David Tolnay
40db31691a
Allow borrow attribute on newtype variants
2017-11-05 12:10:40 -08:00
David Tolnay
aa03fd5d1a
Duplicate error messages have been fixed
2017-10-27 21:08:41 -04:00
David Tolnay
2e597ed3f0
Remove unused functions in with-variant tests
...
Macro expansion fails before it would generate code to call any of these.
2017-09-09 10:58:32 -07:00
Michael Smith
9fc180e62f
Implement deserialize_with for variants
...
Complements variant serialize_with and closes #1013 .
2017-08-14 14:41:05 -07:00
Michael Smith
5b815b7001
Implement serialize_with for variants
...
As discussed in #1013 , serialize_with functions attached to variants receive an
argument for each inner value contained within the variant. Internally such a
function is wired up to the serializer as if the variant were a newtype variant.
2017-08-14 11:17:08 -07:00
David Tolnay
f39b1db96a
Additional errors for some reason
2017-07-09 09:22:20 -07:00
David Tolnay
cdfd445528
Generate deserialize impls for identifiers
2017-04-14 21:53:48 -07:00
David Tolnay
3f920f645c
License boilerplate
2017-04-13 17:34:42 -07:00
David Tolnay
6a6606cd64
Test unknown field in remote struct
2017-04-10 12:23:02 -07:00
David Tolnay
174867295b
Test missing field in remote struct
2017-04-10 12:22:51 -07:00
David Tolnay
ad5bf04c4e
Test for incorrect remote type deserializing
2017-04-10 12:15:40 -07:00
David Tolnay
2deacf8eaa
Detect incorrect remote type without getter
2017-04-10 12:12:00 -07:00
David Tolnay
5ec317a899
More compile-fail tests for remote derive
2017-04-09 11:11:27 -07:00
David Tolnay
9d8987bde8
Require getters to return the correct type
2017-04-09 10:59:54 -07:00
David Tolnay
fb48111e46
Derive for borrowed fields
2017-04-03 00:40:45 -07:00
David Tolnay
42b2fd8eec
Improve error message parsing from and into
2017-03-18 09:22:44 -07:00
John Baublitz
bc946e4fd7
Macro attributes to specify From and Into trait types for structs and enums ( #817 )
...
* serde macro support for type conversions through From and Into trait
* Revisions requested by dtolnay
* Additional changes requested by dtolnay
2017-03-18 09:22:27 -07:00
Thomas de Zeeuw
7bee779514
Only allow #[serde(default)]` on structs
2017-02-21 00:15:00 +01:00
David Tolnay
c590df13b9
Add compile-fail test for the with
attribute
2017-02-16 18:43:04 -08:00
David Tolnay
45a36f1219
Fix proc macro panic message in tests
2017-02-08 08:12:32 -08:00
David Tolnay
ff21d557c7
Untagged and internally tagged enums
2017-02-02 18:48:30 -08:00
David Tolnay
7a2bfdc1dd
Consistent underscores in root directory
2017-01-25 20:45:33 -08:00