syntax: Add a source field to Local
for tracking if it comes from let
s or for
s.
This commit is contained in:
parent
6fad19e16b
commit
6ddd40d436
5 changed files with 17 additions and 2 deletions
|
@ -439,6 +439,7 @@ impl<'a> AstBuilder for ExtCtxt<'a> {
|
|||
init: Some(ex),
|
||||
id: ast::DUMMY_NODE_ID,
|
||||
span: sp,
|
||||
source: ast::LocalLet,
|
||||
};
|
||||
let decl = respan(sp, ast::DeclLocal(local));
|
||||
@respan(sp, ast::StmtDecl(@decl, ast::DUMMY_NODE_ID))
|
||||
|
@ -462,6 +463,7 @@ impl<'a> AstBuilder for ExtCtxt<'a> {
|
|||
init: Some(ex),
|
||||
id: ast::DUMMY_NODE_ID,
|
||||
span: sp,
|
||||
source: ast::LocalLet,
|
||||
};
|
||||
let decl = respan(sp, ast::DeclLocal(local));
|
||||
@respan(sp, ast::StmtDecl(@decl, ast::DUMMY_NODE_ID))
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue