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

Unified Diff: lib/compiler/implementation/apiimpl.dart

Issue 10963055: [dart2dart] Make removal of asserts and forcing type strips go under (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 8 years, 2 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 | lib/compiler/implementation/compiler.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: lib/compiler/implementation/apiimpl.dart
diff --git a/lib/compiler/implementation/apiimpl.dart b/lib/compiler/implementation/apiimpl.dart
index 30e498925241261a4494475595f90dde6ada870c..e2598605a37b76814a286ad7138ad9928e8a8cd0 100644
--- a/lib/compiler/implementation/apiimpl.dart
+++ b/lib/compiler/implementation/apiimpl.dart
@@ -31,8 +31,16 @@ class Compiler extends leg.Compiler {
enableUserAssertions: hasOption(options, '--enable-checked-mode'),
enableMinification: hasOption(options, '--minify'),
emitJavaScript: !hasOption(options, '--output-type=dart'),
- forceCutDeclarationTypes:
- hasOption(options, '--force-cut-declaration-types'));
+ strips: getStrips(options));
+
+ static List<String> getStrips(List<String> options) {
+ for (String option in options) {
+ if (option.startsWith('--force-strip=')) {
+ return option.substring('--force-strip='.length).split(',');
+ }
+ }
+ return [];
+ }
static bool hasOption(List<String> options, String option) {
return options.indexOf(option) >= 0;
« no previous file with comments | « no previous file | lib/compiler/implementation/compiler.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698