-
-
Notifications
You must be signed in to change notification settings - Fork 1.1k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
This is intended to replace the runtime usage parser and is not meant to be a complete API in of itself, like `clap_app!`. What is in scope is everything that visually makes sense as in a usage string (see [docopt](http://docopt.org/) for inspiration). General setting of attributes is out of scope. This deviates from both `clap_app` and the runtime usage parser - `clap_app` supported multiple values but has a bug because we made `Arg::value_name` non-appending, so we aren't supporting this yet - We do not yet support optional flags that take a value - In both, `...` is multiple occurrences and values while its only multiple occurrences for us - We explicitly support optional values for flags - Unlike `clap_app`, our name is optional - Unlike runtime usage parser, our name syntax is simpler - Unlike runtime usage parser, our name syntax does not allow modifiers Its more limited than I would like. Hopefully some people better with macros can expand the feature set and turn more runtime errors into compile-time errors. This is to prepare for deprecating the runtime usage parser (#8).
- Loading branch information
Showing
2 changed files
with
476 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.