diff options
| author | Oliver Schneider <git-spam-no-reply9815368754983@oli-obk.de> | 2016-02-08 15:34:47 +0100 |
|---|---|---|
| committer | Oliver Schneider <git-spam-no-reply9815368754983@oli-obk.de> | 2016-02-11 12:34:48 +0100 |
| commit | 79fa657abc6b8885ceb4023099b4e0026c5ef28f (patch) | |
| tree | 47b5b4bada4def35e5da8f19b4af309f887c8421 /src/libsyntax/ext | |
| parent | 8516ba367d1f51318ce373fe9b60650c82ded1e9 (diff) | |
| download | rust-79fa657abc6b8885ceb4023099b4e0026c5ef28f.tar.gz rust-79fa657abc6b8885ceb4023099b4e0026c5ef28f.zip | |
[breaking-change] don't glob export ast::Decl_ variants
Diffstat (limited to 'src/libsyntax/ext')
| -rw-r--r-- | src/libsyntax/ext/build.rs | 6 | ||||
| -rw-r--r-- | src/libsyntax/ext/expand.rs | 6 |
2 files changed, 6 insertions, 6 deletions
diff --git a/src/libsyntax/ext/build.rs b/src/libsyntax/ext/build.rs index 5980cf3abcc..3a69b84ab3c 100644 --- a/src/libsyntax/ext/build.rs +++ b/src/libsyntax/ext/build.rs @@ -524,7 +524,7 @@ impl<'a> AstBuilder for ExtCtxt<'a> { span: sp, attrs: None, }); - let decl = respan(sp, ast::DeclLocal(local)); + let decl = respan(sp, ast::DeclKind::Local(local)); P(respan(sp, ast::StmtDecl(P(decl), ast::DUMMY_NODE_ID))) } @@ -548,7 +548,7 @@ impl<'a> AstBuilder for ExtCtxt<'a> { span: sp, attrs: None, }); - let decl = respan(sp, ast::DeclLocal(local)); + let decl = respan(sp, ast::DeclKind::Local(local)); P(respan(sp, ast::StmtDecl(P(decl), ast::DUMMY_NODE_ID))) } @@ -558,7 +558,7 @@ impl<'a> AstBuilder for ExtCtxt<'a> { } fn stmt_item(&self, sp: Span, item: P<ast::Item>) -> P<ast::Stmt> { - let decl = respan(sp, ast::DeclItem(item)); + let decl = respan(sp, ast::DeclKind::Item(item)); P(respan(sp, ast::StmtDecl(P(decl), ast::DUMMY_NODE_ID))) } diff --git a/src/libsyntax/ext/expand.rs b/src/libsyntax/ext/expand.rs index 72537f6c7b2..460d564a70e 100644 --- a/src/libsyntax/ext/expand.rs +++ b/src/libsyntax/ext/expand.rs @@ -8,7 +8,7 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -use ast::{Block, Crate, DeclLocal, PatMac}; +use ast::{Block, Crate, DeclKind, PatMac}; use ast::{Local, Ident, Mac_, Name}; use ast::{ItemMac, MacStmtWithSemicolon, Mrk, Stmt, StmtDecl, StmtMac}; use ast::{StmtExpr, StmtSemi}; @@ -559,7 +559,7 @@ fn expand_non_macro_stmt(Spanned {node, span: stmt_span}: Stmt, fld: &mut MacroE // is it a let? match node { StmtDecl(decl, node_id) => decl.and_then(|Spanned {node: decl, span}| match decl { - DeclLocal(local) => { + DeclKind::Local(local) => { // take it apart: let rewritten_local = local.map(|Local {id, pat, ty, init, span, attrs}| { // expand the ty since TyFixedLengthVec contains an Expr @@ -597,7 +597,7 @@ fn expand_non_macro_stmt(Spanned {node, span: stmt_span}: Stmt, fld: &mut MacroE }); SmallVector::one(P(Spanned { node: StmtDecl(P(Spanned { - node: DeclLocal(rewritten_local), + node: DeclKind::Local(rewritten_local), span: span }), node_id), |
