| 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:io' | 9 import 'dart:io' |
| 10 show exit, File, FileMode, Platform, RandomAccessFile, FileSystemException, | 10 show exit, File, FileMode, Platform, RandomAccessFile, FileSystemException, |
| (...skipping 270 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 281 (_) => diagnosticHandler.showHints = false), | 281 (_) => diagnosticHandler.showHints = false), |
| 282 new OptionHandler( | 282 new OptionHandler( |
| 283 '--output-type=dart|--output-type=dart-multi|--output-type=js', | 283 '--output-type=dart|--output-type=dart-multi|--output-type=js', |
| 284 setOutputType), | 284 setOutputType), |
| 285 new OptionHandler('--verbose', setVerbose), | 285 new OptionHandler('--verbose', setVerbose), |
| 286 new OptionHandler('--version', (_) => wantVersion = true), | 286 new OptionHandler('--version', (_) => wantVersion = true), |
| 287 new OptionHandler('--library-root=.+', setLibraryRoot), | 287 new OptionHandler('--library-root=.+', setLibraryRoot), |
| 288 new OptionHandler('--out=.+|-o.*', setOutput, multipleArguments: true), | 288 new OptionHandler('--out=.+|-o.*', setOutput, multipleArguments: true), |
| 289 new OptionHandler('--allow-mock-compilation', passThrough), | 289 new OptionHandler('--allow-mock-compilation', passThrough), |
| 290 new OptionHandler('--minify|-m', implyCompilation), | 290 new OptionHandler('--minify|-m', implyCompilation), |
| 291 new OptionHandler('--preserve-uris', passThrough), |
| 291 new OptionHandler('--force-strip=.*', setStrip), | 292 new OptionHandler('--force-strip=.*', setStrip), |
| 292 new OptionHandler('--disable-diagnostic-colors', | 293 new OptionHandler('--disable-diagnostic-colors', |
| 293 (_) => diagnosticHandler.enableColors = false), | 294 (_) => diagnosticHandler.enableColors = false), |
| 294 new OptionHandler('--enable-diagnostic-colors', | 295 new OptionHandler('--enable-diagnostic-colors', |
| 295 (_) => diagnosticHandler.enableColors = true), | 296 (_) => diagnosticHandler.enableColors = true), |
| 296 new OptionHandler('--enable[_-]checked[_-]mode|--checked', | 297 new OptionHandler('--enable[_-]checked[_-]mode|--checked', |
| 297 (_) => setCheckedMode('--enable-checked-mode')), | 298 (_) => setCheckedMode('--enable-checked-mode')), |
| 298 new OptionHandler('--enable-concrete-type-inference', | 299 new OptionHandler('--enable-concrete-type-inference', |
| 299 (_) => implyCompilation( | 300 (_) => implyCompilation( |
| 300 '--enable-concrete-type-inference')), | 301 '--enable-concrete-type-inference')), |
| (...skipping 216 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 517 --enable-diagnostic-colors | 518 --enable-diagnostic-colors |
| 518 Add colors to diagnostic messages. | 519 Add colors to diagnostic messages. |
| 519 | 520 |
| 520 --terse | 521 --terse |
| 521 Emit diagnostics without suggestions for how to get rid of the diagnosed | 522 Emit diagnostics without suggestions for how to get rid of the diagnosed |
| 522 problems. | 523 problems. |
| 523 | 524 |
| 524 --show-package-warnings | 525 --show-package-warnings |
| 525 Show warnings and hints generated from packages. | 526 Show warnings and hints generated from packages. |
| 526 | 527 |
| 528 --preserve-uris |
| 529 Preserve the source URIs in the reflection data. Without this flag the |
| 530 `uri` getter for `LibraryMirror`s is mangled in minified mode. |
| 531 |
| 527 --csp | 532 --csp |
| 528 Disables dynamic generation of code in the generated output. This is | 533 Disables dynamic generation of code in the generated output. This is |
| 529 necessary to satisfy CSP restrictions (see http://www.w3.org/TR/CSP/). | 534 necessary to satisfy CSP restrictions (see http://www.w3.org/TR/CSP/). |
| 530 | 535 |
| 531 The following options are only used for compiler development and may | 536 The following options are only used for compiler development and may |
| 532 be removed in a future version: | 537 be removed in a future version: |
| 533 | 538 |
| 534 --output-type=dart | 539 --output-type=dart |
| 535 Output Dart code instead of JavaScript. | 540 Output Dart code instead of JavaScript. |
| 536 | 541 |
| (...skipping 128 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 665 } else { | 670 } else { |
| 666 print(">>> TEST FAIL"); | 671 print(">>> TEST FAIL"); |
| 667 } | 672 } |
| 668 stderr.writeln(">>> EOF STDERR"); | 673 stderr.writeln(">>> EOF STDERR"); |
| 669 runJob(); | 674 runJob(); |
| 670 }); | 675 }); |
| 671 } | 676 } |
| 672 | 677 |
| 673 runJob(); | 678 runJob(); |
| 674 } | 679 } |
| OLD | NEW |