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

Unified Diff: lib/compiler/implementation/ssa/builder.dart

Issue 10540052: Only generate assert in checked mode. (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 8 years, 6 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: lib/compiler/implementation/ssa/builder.dart
===================================================================
--- lib/compiler/implementation/ssa/builder.dart (revision 8394)
+++ lib/compiler/implementation/ssa/builder.dart (working copy)
@@ -2372,6 +2372,10 @@
visitStaticSend(Send node) {
Selector selector = elements.getSelector(node);
Element element = elements[node];
+ if (element == compiler.assertMethod && !compiler.enableUserAssertions) {
kasperl 2012/06/08 05:34:05 ===?
ngeoffray 2012/06/08 09:40:58 Done.
+ stack.add(graph.addConstantNull());
karlklose 2012/06/08 07:42:42 I guess we add null here because we do not check t
ahe 2012/06/08 07:59:14 I don't think Nicolas needs to worry about this no
ngeoffray 2012/06/08 09:40:58 OK. Note that I think we will keep the the addCons
+ return;
+ }
compiler.ensure(element.kind !== ElementKind.GENERATIVE_CONSTRUCTOR);
HInstruction target = new HStatic(element);
add(target);

Powered by Google App Engine
This is Rietveld 408576698