Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file |
| 2 // for details. All rights reserved. Use of this source code is governed by a | 2 // for details. All rights reserved. Use of this source code is governed by a |
| 3 // BSD-style license that can be found in the LICENSE file. | 3 // BSD-style license that can be found in the LICENSE file. |
| 4 | 4 |
| 5 library leg_apiimpl; | 5 library leg_apiimpl; |
| 6 | 6 |
| 7 import 'dart:async'; | 7 import 'dart:async'; |
| 8 | 8 |
| 9 import '../compiler.dart' as api; | 9 import '../compiler.dart' as api; |
| 10 import 'dart2jslib.dart' as leg; | 10 import 'dart2jslib.dart' as leg; |
| (...skipping 24 matching lines...) Expand all Loading... | |
| 35 this.allowedLibraryCategories = getAllowedLibraryCategories(options), | 35 this.allowedLibraryCategories = getAllowedLibraryCategories(options), |
| 36 super( | 36 super( |
| 37 outputProvider: outputProvider, | 37 outputProvider: outputProvider, |
| 38 enableTypeAssertions: hasOption(options, '--enable-checked-mode'), | 38 enableTypeAssertions: hasOption(options, '--enable-checked-mode'), |
| 39 enableUserAssertions: hasOption(options, '--enable-checked-mode'), | 39 enableUserAssertions: hasOption(options, '--enable-checked-mode'), |
| 40 trustTypeAnnotations: | 40 trustTypeAnnotations: |
| 41 hasOption(options, '--trust-type-annotations'), | 41 hasOption(options, '--trust-type-annotations'), |
| 42 enableMinification: hasOption(options, '--minify'), | 42 enableMinification: hasOption(options, '--minify'), |
| 43 enableNativeLiveTypeAnalysis: | 43 enableNativeLiveTypeAnalysis: |
| 44 !hasOption(options, '--disable-native-live-type-analysis'), | 44 !hasOption(options, '--disable-native-live-type-analysis'), |
| 45 emitJavaScript: !hasOption(options, '--output-type=dart'), | 45 emitJavaScript: !(hasOption(options, '--output-type=dart') || |
| 46 hasOption(options, '--output-type=dart-multi')), | |
| 47 dart2dartMultiFile: !hasOption(options, '--output-type=dart'), | |
|
jgruber1
2014/08/15 06:20:53
Why the negative logic? If multi-file is not inten
sigurdm
2014/08/15 13:31:42
Good point.
Done.
| |
| 46 generateSourceMap: !hasOption(options, '--no-source-maps'), | 48 generateSourceMap: !hasOption(options, '--no-source-maps'), |
| 47 analyzeAllFlag: hasOption(options, '--analyze-all'), | 49 analyzeAllFlag: hasOption(options, '--analyze-all'), |
| 48 analyzeOnly: hasOption(options, '--analyze-only'), | 50 analyzeOnly: hasOption(options, '--analyze-only'), |
| 49 analyzeMain: hasOption(options, '--analyze-main'), | 51 analyzeMain: hasOption(options, '--analyze-main'), |
| 50 analyzeSignaturesOnly: | 52 analyzeSignaturesOnly: |
| 51 hasOption(options, '--analyze-signatures-only'), | 53 hasOption(options, '--analyze-signatures-only'), |
| 52 strips: extractCsvOption(options, '--force-strip='), | 54 strips: extractCsvOption(options, '--force-strip='), |
| 53 enableConcreteTypeInference: | 55 enableConcreteTypeInference: |
| 54 hasOption(options, '--enable-concrete-type-inference'), | 56 hasOption(options, '--enable-concrete-type-inference'), |
| 55 disableTypeInferenceFlag: | 57 disableTypeInferenceFlag: |
| (...skipping 274 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 330 } | 332 } |
| 331 | 333 |
| 332 void diagnoseCrashInUserCode(String message, exception, stackTrace) { | 334 void diagnoseCrashInUserCode(String message, exception, stackTrace) { |
| 333 hasCrashed = true; | 335 hasCrashed = true; |
| 334 print('$message: ${tryToString(exception)}'); | 336 print('$message: ${tryToString(exception)}'); |
| 335 print(tryToString(stackTrace)); | 337 print(tryToString(stackTrace)); |
| 336 } | 338 } |
| 337 | 339 |
| 338 fromEnvironment(String name) => environment[name]; | 340 fromEnvironment(String name) => environment[name]; |
| 339 } | 341 } |
| OLD | NEW |