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

Unified Diff: tools/testing/dart/compiler_configuration.dart

Issue 1330643003: This is a fixed up version of: (Closed) Base URL: https://github.com/dart-lang/sdk.git@master
Patch Set: Created 5 years, 3 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: tools/testing/dart/compiler_configuration.dart
diff --git a/tools/testing/dart/compiler_configuration.dart b/tools/testing/dart/compiler_configuration.dart
index fc1d536e0e0f649d5a505dc54ddb237e28e9e9f6..9ec90f002715c64f17edc836b5500d806c110f8e 100644
--- a/tools/testing/dart/compiler_configuration.dart
+++ b/tools/testing/dart/compiler_configuration.dart
@@ -155,7 +155,12 @@ class NoneCompilerConfiguration extends CompilerConfiguration {
List<String> sharedOptions,
List<String> originalArguments,
CommandArtifact artifact) {
- return <String>[]
+ List<String> args = [];
+ if (isChecked) {
+ args.add('--enable_asserts');
+ args.add('--enable_type_checks');
+ }
+ return args
..addAll(vmOptions)
..addAll(sharedOptions)
..addAll(originalArguments);
@@ -315,6 +320,10 @@ class AnalyzerCompilerConfiguration extends CompilerConfiguration {
CommandBuilder commandBuilder,
List arguments,
Map<String, String> environmentOverrides) {
+ arguments = new List.from(arguments);
+ if (isChecked) {
+ arguments.add('--enable_type_checks');
+ }
return new CommandArtifact(
<Command>[
commandBuilder.getAnalysisCommand(

Powered by Google App Engine
This is Rietveld 408576698