Merge pull request #571 from nrc/semi

Don't strip semi-colons from expressions with non-void type since it …
This commit is contained in:
Marcus Klaas de Vries
2015-11-10 08:43:29 +01:00
3 changed files with 4 additions and 8 deletions
+1 -5
View File
@@ -507,12 +507,8 @@ fn semicolon_for_stmt(stmt: &ast::Stmt) -> bool {
match expr.node {
ast::Expr_::ExprWhile(..) |
ast::Expr_::ExprWhileLet(..) |
ast::Expr_::ExprIf(..) |
ast::Expr_::ExprIfLet(..) |
ast::Expr_::ExprBlock(..) |
ast::Expr_::ExprLoop(..) |
ast::Expr_::ExprForLoop(..) |
ast::Expr_::ExprMatch(..) => false,
ast::Expr_::ExprForLoop(..) => false,
_ => true,
}
}