Skip to content

Commit

Permalink
refactor(ast_tools): shorter code in AstKindGenerator
Browse files Browse the repository at this point in the history
  • Loading branch information
overlookmotel committed Oct 22, 2024
1 parent d9e060d commit e167a03
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions tasks/ast_tools/src/generators/ast_kind.rs
Original file line number Diff line number Diff line change
Expand Up @@ -96,8 +96,7 @@ impl Generator for AstKindGenerator {
})
.collect_vec();

let types: Vec<Variant> =
have_kinds.iter().map(|(ident, _)| parse_quote!(#ident)).collect_vec();
let types = have_kinds.iter().map(|(ident, _)| ident).collect_vec();

let kinds: Vec<Variant> =
have_kinds.iter().map(|(ident, typ)| parse_quote!(#ident(&'a #typ))).collect_vec();
Expand Down

0 comments on commit e167a03

Please sign in to comment.