Rollup merge of #34316 - jseyfried:refactor_ast_stmt, r=eddyb
Refactor away `ast::Decl`, refactor `ast::Stmt`, and rename `ast::ExprKind::Again` to `ast::ExprKind::Continue`.
This commit is contained in:
@@ -13,7 +13,6 @@ use deriving::generic::ty::*;
|
||||
|
||||
use syntax::ast;
|
||||
use syntax::ast::{MetaItem, Expr};
|
||||
use syntax::codemap::respan;
|
||||
use syntax::ext::base::{ExtCtxt, Annotatable};
|
||||
use syntax::ext::build::AstBuilder;
|
||||
use syntax::parse::token;
|
||||
@@ -152,6 +151,9 @@ fn stmt_let_undescore(cx: &mut ExtCtxt,
|
||||
span: sp,
|
||||
attrs: None,
|
||||
});
|
||||
let decl = respan(sp, ast::DeclKind::Local(local));
|
||||
respan(sp, ast::StmtKind::Decl(P(decl), ast::DUMMY_NODE_ID))
|
||||
ast::Stmt {
|
||||
id: ast::DUMMY_NODE_ID,
|
||||
node: ast::StmtKind::Local(local),
|
||||
span: sp,
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user