Fix for "cannot infer type" from Deserialize derive macro with simple

variants and untagged variants
This commit is contained in:
Adam H. Leventhal
2023-09-06 15:25:05 -07:00
parent 5d1403461c
commit 09993a904a
2 changed files with 12 additions and 3 deletions
+3 -2
View File
@@ -2383,7 +2383,7 @@ fn test_partially_untagged_enum_desugared() {
#[test]
fn test_partially_untagged_simple_enum() {
#[derive(Serialize, Deserialize, PartialEq, Debug)]
#[serde(tag = "tag")]
#[serde(tag = "t")]
enum Data {
A,
#[serde(untagged)]
@@ -2391,7 +2391,8 @@ fn test_partially_untagged_simple_enum() {
}
let data = Data::A;
assert_tokens(
assert_de_tokens(
&data,
&[
Token::Map { len: None },