aboutsummaryrefslogtreecommitdiff
path: root/xtask/src/codegen
diff options
context:
space:
mode:
Diffstat (limited to 'xtask/src/codegen')
-rw-r--r--xtask/src/codegen/gen_syntax.rs2
-rw-r--r--xtask/src/codegen/rust.ungram1
2 files changed, 2 insertions, 1 deletions
diff --git a/xtask/src/codegen/gen_syntax.rs b/xtask/src/codegen/gen_syntax.rs
index 24e8be1fb..9b49712c1 100644
--- a/xtask/src/codegen/gen_syntax.rs
+++ b/xtask/src/codegen/gen_syntax.rs
@@ -374,6 +374,7 @@ fn generate_syntax_kinds(grammar: KindsSrc<'_>) -> Result<String> {
374 #([#all_keywords_idents] => { $crate::SyntaxKind::#all_keywords };)* 374 #([#all_keywords_idents] => { $crate::SyntaxKind::#all_keywords };)*
375 [lifetime] => { $crate::SyntaxKind::LIFETIME }; 375 [lifetime] => { $crate::SyntaxKind::LIFETIME };
376 [ident] => { $crate::SyntaxKind::IDENT }; 376 [ident] => { $crate::SyntaxKind::IDENT };
377 [shebang] => { $crate::SyntaxKind::SHEBANG };
377 } 378 }
378 }; 379 };
379 380
@@ -595,7 +596,6 @@ fn lower_rule(acc: &mut Vec<Field>, grammar: &Grammar, rule: &Rule) {
595} 596}
596 597
597fn deduplicate_fields(ast: &mut AstSrc) { 598fn deduplicate_fields(ast: &mut AstSrc) {
598 eprintln!();
599 for node in &mut ast.nodes { 599 for node in &mut ast.nodes {
600 let mut i = 0; 600 let mut i = 0;
601 'outer: while i < node.fields.len() { 601 'outer: while i < node.fields.len() {
diff --git a/xtask/src/codegen/rust.ungram b/xtask/src/codegen/rust.ungram
index 08db70093..a93cb3815 100644
--- a/xtask/src/codegen/rust.ungram
+++ b/xtask/src/codegen/rust.ungram
@@ -1,4 +1,5 @@
1SourceFile = 1SourceFile =
2 'shebang'?
2 Attr* 3 Attr*
3 Item* 4 Item*
4 5