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

Unified Diff: pkg/compiler/lib/src/ssa/nodes.dart

Issue 1079253002: Use native behavior for dead code elimination (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
Index: pkg/compiler/lib/src/ssa/nodes.dart
diff --git a/pkg/compiler/lib/src/ssa/nodes.dart b/pkg/compiler/lib/src/ssa/nodes.dart
index d7be40ce86e154d05bd3188e2e6d6c6c29920e6e..1f060bb62598bee58be1068c1da9d9e9ca399366 100644
--- a/pkg/compiler/lib/src/ssa/nodes.dart
+++ b/pkg/compiler/lib/src/ssa/nodes.dart
@@ -1750,7 +1750,11 @@ class HForeignCode extends HForeign {
accept(HVisitor visitor) => visitor.visitForeignCode(this);
bool isJsStatement() => isStatement;
- bool canThrow() => throwBehavior.canThrow;
+ bool canThrow() => canBeNull()
+ ? throwBehavior.canThrow
+ : throwBehavior.onNonNull.canThrow;
+
+ bool onlyThrowsNSM() => throwBehavior.onlyNullNSMGuard;
}
class HForeignNew extends HForeign {

Powered by Google App Engine
This is Rietveld 408576698