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

Unified Diff: samples/build_dart/build.dart

Issue 52573002: Remove uses of Options from pkg, samples, tests, and third_party directories. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Edit comment Created 7 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 | « pkg/watcher/example/watch.dart ('k') | samples/build_dart_simple/build.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: samples/build_dart/build.dart
diff --git a/samples/build_dart/build.dart b/samples/build_dart/build.dart
index 07817b5dfdaf0dc0759468c768cdfdd2cce8a958..d2def22770ef5dd4007ccb3b1db41fa96084c041 100644
--- a/samples/build_dart/build.dart
+++ b/samples/build_dart/build.dart
@@ -21,8 +21,8 @@ List<String> removedFiles;
* See the source code of [processArgs] for information about the legal command
* line options.
*/
-void main() {
- processArgs();
+void main(List<String> arguments) {
+ processArgs(arguments);
if (cleanBuild) {
handleCleanCommand();
@@ -40,7 +40,7 @@ void main() {
/**
* Handle --changed, --removed, --clean, --full, and --help command-line args.
*/
-void processArgs() {
+void processArgs(List<String> arguments) {
var parser = new ArgParser();
parser.addOption("changed", help: "the file has changed since the last build",
allowMultiple: true);
@@ -52,7 +52,7 @@ void processArgs() {
negatable: false, help: "produce warnings in a machine parseable format");
parser.addFlag("help", negatable: false, help: "display this help and exit");
- var args = parser.parse(new Options().arguments);
+ var args = parser.parse(arguments);
if (args["help"]) {
print(parser.getUsage());
« no previous file with comments | « pkg/watcher/example/watch.dart ('k') | samples/build_dart_simple/build.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698