From c021ba48a70e69fa681ea6617512ae2028e2677a Mon Sep 17 00:00:00 2001 From: Mark Rousskov Date: Wed, 9 Feb 2022 17:20:43 -0500 Subject: Delete Decoder::read_struct --- compiler/rustc_macros/src/serialize.rs | 10 +--------- 1 file changed, 1 insertion(+), 9 deletions(-) (limited to 'compiler/rustc_macros') diff --git a/compiler/rustc_macros/src/serialize.rs b/compiler/rustc_macros/src/serialize.rs index 2c4b794ffa1..af8b85f25fd 100644 --- a/compiler/rustc_macros/src/serialize.rs +++ b/compiler/rustc_macros/src/serialize.rs @@ -42,15 +42,7 @@ fn decodable_body( } let ty_name = s.ast().ident.to_string(); let decode_body = match s.variants() { - [vi] => { - let construct = vi.construct(|field, index| decode_field(field, index, true)); - quote! { - ::rustc_serialize::Decoder::read_struct( - __decoder, - |__decoder| { #construct }, - ) - } - } + [vi] => vi.construct(|field, index| decode_field(field, index, true)), variants => { let match_inner: TokenStream = variants .iter() -- cgit 1.4.1-3-g733a5