From 42987a5b246af51a42b158665c63b4ec052e2b3c Mon Sep 17 00:00:00 2001 From: David Tolnay Date: Mon, 3 Oct 2016 13:37:46 -0700 Subject: [PATCH] Fix break in quote 0.2.2 --- serde_codegen/src/de.rs | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/serde_codegen/src/de.rs b/serde_codegen/src/de.rs index ec2f9026..4e74b5fa 100644 --- a/serde_codegen/src/de.rs +++ b/serde_codegen/src/de.rs @@ -651,14 +651,6 @@ fn deserialize_field_visitor( Some(quote!(__ignore,)) }; - let field_enum = quote! { - #[allow(non_camel_case_types)] - enum __Field { - #(field_idents,)* - #ignore_variant - } - }; - let index_field_arms: Vec<_> = field_idents.iter() .enumerate() .map(|(field_index, field_ident)| { @@ -745,6 +737,14 @@ fn deserialize_field_visitor( } }; + let field_enum = quote! { + #[allow(non_camel_case_types)] + enum __Field { + #(field_idents,)* + #ignore_variant + } + }; + let impl_item = quote! { impl _serde::de::Deserialize for __Field { #[inline]