Chromium Code Reviews| Index: lib/src/codegen/js_codegen.dart |
| diff --git a/lib/src/codegen/js_codegen.dart b/lib/src/codegen/js_codegen.dart |
| index cab929bd70d137c3efa53f87444d8ac90046572a..028a5152f56f0ae9ab30c4dd018c910a93fdb44d 100644 |
| --- a/lib/src/codegen/js_codegen.dart |
| +++ b/lib/src/codegen/js_codegen.dart |
| @@ -1241,6 +1241,7 @@ class JSCodegenVisitor extends GeneralizingAstVisitor with ConversionVisitor { |
| JS.Expression _emitPrefixIncrement(Token op, Expression expr) { |
| var one = AstBuilder.integerLiteral(1); |
| + one.staticType = rules.provider.intType; |
| var increment = AstBuilder.binaryExpression(expr, op.lexeme[0], one); |
| return _emitAssignment(expr, increment); |
| } |
| @@ -1516,7 +1517,7 @@ class JSCodegenVisitor extends GeneralizingAstVisitor with ConversionVisitor { |
| } |
| var catchVarDecl = new JS.VariableDeclaration(_catchParameter); |
| - var catchBody = _statement(_visitList(clauses)); |
| + var catchBody = new JS.Block(_visitList(clauses)); |
|
vsm
2015/03/10 13:34:47
The js ast code asserts this is a block.
Jennifer Messerly
2015/03/10 15:04:08
funny! we must've only hit the code path for >2 st
|
| _catchParameter = savedCatch; |
| return new JS.Catch(catchVarDecl, catchBody); |