diff options
| author | Mark Rousskov <mark.simulacrum@gmail.com> | 2022-02-09 17:12:20 -0500 |
|---|---|---|
| committer | Mark Rousskov <mark.simulacrum@gmail.com> | 2022-02-20 18:58:22 -0500 |
| commit | c87060a72d68f7df1feaaa395437ce33e9856399 (patch) | |
| tree | d41bedb9b163ba34c9af6f1858dab1ddc155e35c /compiler/rustc_macros/src/serialize.rs | |
| parent | c6bd6b444ca7718eca5bbd86a4438e779f31dc5e (diff) | |
| download | rust-c87060a72d68f7df1feaaa395437ce33e9856399.tar.gz rust-c87060a72d68f7df1feaaa395437ce33e9856399.zip | |
Delete read_enum_variant names
Diffstat (limited to 'compiler/rustc_macros/src/serialize.rs')
| -rw-r--r-- | compiler/rustc_macros/src/serialize.rs | 8 |
1 files changed, 0 insertions, 8 deletions
diff --git a/compiler/rustc_macros/src/serialize.rs b/compiler/rustc_macros/src/serialize.rs index 91a076fa6f6..8d898291e58 100644 --- a/compiler/rustc_macros/src/serialize.rs +++ b/compiler/rustc_macros/src/serialize.rs @@ -60,13 +60,6 @@ fn decodable_body( quote! { #idx => { #construct } } }) .collect(); - let names: TokenStream = variants - .iter() - .map(|vi| { - let variant_name = vi.ast().ident.to_string(); - quote!(#variant_name,) - }) - .collect(); let message = format!( "invalid enum variant tag while decoding `{}`, expected 0..{}", ty_name, @@ -75,7 +68,6 @@ fn decodable_body( quote! { ::rustc_serialize::Decoder::read_enum_variant( __decoder, - &[#names], |__decoder, __variant_idx| { match __variant_idx { #match_inner |
