Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(48)

Unified Diff: pkg/compiler/lib/src/cps_ir/cps_ir_builder_task.dart

Issue 1087483003: cps-ir: Don't bail on assert in unchecked mode. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 5 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | tests/compiler/dart2js/js_backend_cps_ir_basic_test.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: pkg/compiler/lib/src/cps_ir/cps_ir_builder_task.dart
diff --git a/pkg/compiler/lib/src/cps_ir/cps_ir_builder_task.dart b/pkg/compiler/lib/src/cps_ir/cps_ir_builder_task.dart
index 8909912d34273ae6d77a54eb5a07a31ac550c6c8..b57f0bacf19fed22909cfc85a9d36d894582b489 100644
--- a/pkg/compiler/lib/src/cps_ir/cps_ir_builder_task.dart
+++ b/pkg/compiler/lib/src/cps_ir/cps_ir_builder_task.dart
@@ -636,12 +636,12 @@ abstract class IrBuilderVisitor extends ast.Visitor<ir.Primitive>
// ## Sends ##
@override
- ir.Primitive visitAssert(
- ast.Send node,
- ast.Node condition,
- _) {
+ visitAssert(ast.Send node, ast.Node condition, _) {
karlklose 2015/04/13 12:31:51 I would prefer to keep the type annotation and to
asgerf 2015/04/13 12:35:55 Done.
assert(irBuilder.isOpen);
- return giveup(node, 'Assert');
+ if (!compiler.enableUserAssertions) {
+ return;
+ }
+ giveup(node, 'Assert');
}
ir.Primitive visitNamedArgument(ast.NamedArgument node) {
« no previous file with comments | « no previous file | tests/compiler/dart2js/js_backend_cps_ir_basic_test.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698