Epic rustup of doom

This commit is contained in:
Chris Wong 2015-03-21 13:38:39 +13:00
parent 40612241f2
commit 5988d32562

View file

@ -136,12 +136,12 @@ impl<'cx, 's> Renderer<'cx, 's> {
None => quote_stmt!(self.cx, if $if_cond { $if_body }),
Some(else_body) =>
quote_stmt!(self.cx, if $if_cond { $if_body } else { $else_body }),
};
}.unwrap();
self.stmts.push(stmt);
}
pub fn emit_for(&mut self, pattern: P<Pat>, iterable: P<Expr>, body: Vec<P<Stmt>>) {
let stmt = quote_stmt!(self.cx, for $pattern in $iterable { $body });
let stmt = quote_stmt!(self.cx, for $pattern in $iterable { $body }).unwrap();
self.stmts.push(stmt);
}
}