| OLD | NEW |
| 1 // Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2013, 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 dart2js.cmdline; | 5 library dart2js.cmdline; |
| 6 | 6 |
| 7 import 'dart:async' | 7 import 'dart:async' |
| 8 show Future, EventSink; | 8 show Future, EventSink; |
| 9 import 'dart:convert' show UTF8, LineSplitter; | 9 import 'dart:convert' show UTF8, LineSplitter; |
| 10 import 'dart:io' | 10 import 'dart:io' |
| (...skipping 302 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 313 '--output-type=dart|--output-type=dart-multi|--output-type=js', | 313 '--output-type=dart|--output-type=dart-multi|--output-type=js', |
| 314 setOutputType), | 314 setOutputType), |
| 315 new OptionHandler(Flags.useCpsIr, passThrough), | 315 new OptionHandler(Flags.useCpsIr, passThrough), |
| 316 new OptionHandler(Flags.noFrequencyBasedMinification, passThrough), | 316 new OptionHandler(Flags.noFrequencyBasedMinification, passThrough), |
| 317 new OptionHandler(Flags.verbose, setVerbose), | 317 new OptionHandler(Flags.verbose, setVerbose), |
| 318 new OptionHandler(Flags.version, (_) => wantVersion = true), | 318 new OptionHandler(Flags.version, (_) => wantVersion = true), |
| 319 new OptionHandler('--library-root=.+', setLibraryRoot), | 319 new OptionHandler('--library-root=.+', setLibraryRoot), |
| 320 new OptionHandler('--out=.+|-o.*', setOutput, multipleArguments: true), | 320 new OptionHandler('--out=.+|-o.*', setOutput, multipleArguments: true), |
| 321 new OptionHandler(Flags.allowMockCompilation, passThrough), | 321 new OptionHandler(Flags.allowMockCompilation, passThrough), |
| 322 new OptionHandler(Flags.fastStartup, passThrough), | 322 new OptionHandler(Flags.fastStartup, passThrough), |
| 323 new OptionHandler(Flags.conditionalDirectives, passThrough), |
| 323 new OptionHandler('${Flags.minify}|-m', implyCompilation), | 324 new OptionHandler('${Flags.minify}|-m', implyCompilation), |
| 324 new OptionHandler(Flags.preserveUris, passThrough), | 325 new OptionHandler(Flags.preserveUris, passThrough), |
| 325 new OptionHandler('--force-strip=.*', setStrip), | 326 new OptionHandler('--force-strip=.*', setStrip), |
| 326 new OptionHandler(Flags.disableDiagnosticColors, | 327 new OptionHandler(Flags.disableDiagnosticColors, |
| 327 (_) => diagnosticHandler.enableColors = false), | 328 (_) => diagnosticHandler.enableColors = false), |
| 328 new OptionHandler(Flags.enableDiagnosticColors, | 329 new OptionHandler(Flags.enableDiagnosticColors, |
| 329 (_) => diagnosticHandler.enableColors = true), | 330 (_) => diagnosticHandler.enableColors = true), |
| 330 new OptionHandler('--enable[_-]checked[_-]mode|--checked', | 331 new OptionHandler('--enable[_-]checked[_-]mode|--checked', |
| 331 (_) => setCheckedMode(Flags.enableCheckedMode)), | 332 (_) => setCheckedMode(Flags.enableCheckedMode)), |
| 332 new OptionHandler(Flags.trustTypeAnnotations, | 333 new OptionHandler(Flags.trustTypeAnnotations, |
| (...skipping 433 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 766 } else if (exitCode == 253) { | 767 } else if (exitCode == 253) { |
| 767 print(">>> TEST CRASH"); | 768 print(">>> TEST CRASH"); |
| 768 } else { | 769 } else { |
| 769 print(">>> TEST FAIL"); | 770 print(">>> TEST FAIL"); |
| 770 } | 771 } |
| 771 stderr.writeln(">>> EOF STDERR"); | 772 stderr.writeln(">>> EOF STDERR"); |
| 772 subscription.resume(); | 773 subscription.resume(); |
| 773 }); | 774 }); |
| 774 }); | 775 }); |
| 775 } | 776 } |
| OLD | NEW |