Introduce dedicated AST node for union
Although structs and unions have the same syntax and differ only in the keyword, re-using the single syntax node for both of them leads to confusion in practice, and propagates further down the hir in an upleasent way. Moreover, static and consts also share syntax, but we use different nodes for them.
This commit is contained in:
@@ -122,6 +122,7 @@ pub enum SyntaxKind {
|
||||
R_DOLLAR,
|
||||
SOURCE_FILE,
|
||||
STRUCT_DEF,
|
||||
UNION_DEF,
|
||||
ENUM_DEF,
|
||||
FN_DEF,
|
||||
RET_TYPE,
|
||||
|
||||
Reference in New Issue
Block a user