Skip to content

Commit

Permalink
Format PR 1992 with rustfmt
Browse files Browse the repository at this point in the history
  • Loading branch information
dtolnay committed Aug 21, 2021
1 parent c1ce03b commit 9451ea8
Showing 1 changed file with 2 additions and 8 deletions.
10 changes: 2 additions & 8 deletions serde_derive/src/de.rs
Expand Up @@ -2902,16 +2902,10 @@ fn unwrap_to_variant_closure(
let variant_ident = &variant.ident;

let (arg, wrapper) = if with_wrapper {
(
quote!{ __wrap },
quote!{ __wrap.value },
)
(quote! { __wrap }, quote! { __wrap.value })
} else {
let field_tys = variant.fields.iter().map(|field| field.ty);
(
quote!{ __wrap: (#(#field_tys),*) },
quote!{ __wrap },
)
(quote! { __wrap: (#(#field_tys),*) }, quote! { __wrap })
};

let field_access = (0..variant.fields.len()).map(|n| {
Expand Down

0 comments on commit 9451ea8

Please sign in to comment.