aboutsummaryrefslogtreecommitdiff
path: root/xtask/src/codegen
diff options
context:
space:
mode:
authorbors[bot] <26634292+bors[bot]@users.noreply.github.com>2020-07-30 16:51:06 +0100
committerGitHub <[email protected]>2020-07-30 16:51:06 +0100
commit97df465391f50521c5102474d7e0ee2ea61ef48e (patch)
tree2bda021d9fafc6af927ebfbcafd31537496bd53c /xtask/src/codegen
parent0c8944314cb323416c8ad6ad27347ca056c5a91c (diff)
parent216a5344c8ef3c3e430d2761dc8b1a7b60250a15 (diff)
Merge #5602
5602: Rename StructDef -> Struct r=matklad a=matklad bors r+ 🤖 Co-authored-by: Aleksey Kladov <[email protected]>
Diffstat (limited to 'xtask/src/codegen')
-rw-r--r--xtask/src/codegen/gen_syntax.rs2
-rw-r--r--xtask/src/codegen/rust.ungram6
2 files changed, 4 insertions, 4 deletions
diff --git a/xtask/src/codegen/gen_syntax.rs b/xtask/src/codegen/gen_syntax.rs
index 84ddda5cb..e993a750c 100644
--- a/xtask/src/codegen/gen_syntax.rs
+++ b/xtask/src/codegen/gen_syntax.rs
@@ -307,7 +307,7 @@ fn generate_syntax_kinds(grammar: KindsSrc<'_>) -> Result<String> {
307 307
308 let ast = quote! { 308 let ast = quote! {
309 #![allow(bad_style, missing_docs, unreachable_pub)] 309 #![allow(bad_style, missing_docs, unreachable_pub)]
310 /// The kind of syntax node, e.g. `IDENT`, `USE_KW`, or `STRUCT_DEF`. 310 /// The kind of syntax node, e.g. `IDENT`, `USE_KW`, or `STRUCT`.
311 #[derive(Clone, Copy, PartialEq, Eq, PartialOrd, Ord, Hash, Debug)] 311 #[derive(Clone, Copy, PartialEq, Eq, PartialOrd, Ord, Hash, Debug)]
312 #[repr(u16)] 312 #[repr(u16)]
313 pub enum SyntaxKind { 313 pub enum SyntaxKind {
diff --git a/xtask/src/codegen/rust.ungram b/xtask/src/codegen/rust.ungram
index 65082f3d9..d038c5c5a 100644
--- a/xtask/src/codegen/rust.ungram
+++ b/xtask/src/codegen/rust.ungram
@@ -13,7 +13,7 @@ Item =
13| MacroCall 13| MacroCall
14| Module 14| Module
15| StaticDef 15| StaticDef
16| StructDef 16| Struct
17| TraitDef 17| TraitDef
18| TypeAlias 18| TypeAlias
19| Union 19| Union
@@ -76,7 +76,7 @@ TypeAlias =
76 Attr* Visibility? 'default'? 'type' Name GenericParamList? (':' TypeBoundList?)? WhereClause? 76 Attr* Visibility? 'default'? 'type' Name GenericParamList? (':' TypeBoundList?)? WhereClause?
77 '=' TypeRef ';' 77 '=' TypeRef ';'
78 78
79StructDef = 79Struct =
80 Attr* Visibility? 'struct' Name GenericParamList? ( 80 Attr* Visibility? 'struct' Name GenericParamList? (
81 WhereClause? (RecordFieldList | ';') 81 WhereClause? (RecordFieldList | ';')
82 | TupleFieldList WhereClause? ';' 82 | TupleFieldList WhereClause? ';'
@@ -453,7 +453,7 @@ MetaItem =
453 Path '=' AttrInput nested_meta_items:MetaItem* 453 Path '=' AttrInput nested_meta_items:MetaItem*
454 454
455AdtDef = 455AdtDef =
456 StructDef 456 Struct
457| EnumDef 457| EnumDef
458| Union 458| Union
459 459