diff options
| author | John Clements <clements@racket-lang.org> | 2014-07-12 18:25:39 -0700 |
|---|---|---|
| committer | John Clements <clements@racket-lang.org> | 2014-07-13 10:10:38 -0700 |
| commit | 6ee2155fe02cf5c7d8717358e2e10aff9a659b5f (patch) | |
| tree | d5d0d78dfe7e18f39cb6108d8f0fc92722fd8b57 /src/libsyntax | |
| parent | c4cc3ba13019daf0cc947727b276941dcde9b623 (diff) | |
| download | rust-6ee2155fe02cf5c7d8717358e2e10aff9a659b5f.tar.gz rust-6ee2155fe02cf5c7d8717358e2e10aff9a659b5f.zip | |
remove no-stmt check
nothing wrong with a statement expanding into 0 stmts, that I can see.
Diffstat (limited to 'src/libsyntax')
| -rw-r--r-- | src/libsyntax/ext/expand.rs | 4 |
1 files changed, 0 insertions, 4 deletions
diff --git a/src/libsyntax/ext/expand.rs b/src/libsyntax/ext/expand.rs index f091217cf5a..6bfe69f3a06 100644 --- a/src/libsyntax/ext/expand.rs +++ b/src/libsyntax/ext/expand.rs @@ -612,10 +612,6 @@ fn expand_stmt(s: &Stmt, fld: &mut MacroExpander) -> SmallVector<Gc<Stmt>> { // Keep going, outside-in. let fully_expanded = fld.fold_stmt(&*marked_after); - if fully_expanded.is_empty() { - fld.cx.span_err(pth.span, "macro didn't expand to a statement"); - return SmallVector::zero(); - } fld.cx.bt_pop(); let fully_expanded: SmallVector<Gc<Stmt>> = fully_expanded.move_iter() .map(|s| box(GC) Spanned { span: s.span, node: s.node.clone() }) |
