Added rust imports with header
This commit is contained in:
@@ -25,6 +25,7 @@ pub enum AstType {
|
||||
CodeBlock,
|
||||
Json,
|
||||
Impl,
|
||||
StaticExecution,
|
||||
Other,
|
||||
}
|
||||
|
||||
@@ -345,6 +346,12 @@ impl Parser {
|
||||
ast_res.tokens.push(token.clone());
|
||||
}
|
||||
}
|
||||
TokenType::StaticExecution => {
|
||||
if self.tokens[index + 1].token_type == TokenType::Square {
|
||||
ast_res.tokens.push(self.tokens[index + 1].clone());
|
||||
ast_res.ast_type = AstType::StaticExecution;
|
||||
}
|
||||
}
|
||||
_ => {
|
||||
ast_res.tokens.push(token.clone());
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user