mirror of
https://github.com/rust-lang/rust-analyzer
synced 2024-12-25 12:33:33 +00:00
Finish Module grammar
This commit is contained in:
parent
081f35fe1b
commit
7d09e5ed61
2 changed files with 2 additions and 1 deletions
|
@ -248,6 +248,7 @@ impl Name {
|
|||
pub struct ItemList {
|
||||
pub(crate) syntax: SyntaxNode,
|
||||
}
|
||||
impl ast::AttrsOwner for ItemList {}
|
||||
impl ast::ModuleItemOwner for ItemList {}
|
||||
impl ItemList {
|
||||
pub fn l_curly_token(&self) -> Option<SyntaxToken> { support::token(&self.syntax, T!['{']) }
|
||||
|
|
|
@ -24,7 +24,7 @@ Module =
|
|||
(ItemList | ';')
|
||||
|
||||
ItemList =
|
||||
'{' Item* '}'
|
||||
'{' Attr* Item* '}'
|
||||
|
||||
FnDef =
|
||||
Attr* Visibility? Abi? 'const' 'default' 'async' 'unsafe' 'fn' Name TypeParamList?
|
||||
|
|
Loading…
Reference in a new issue