-
-
Notifications
You must be signed in to change notification settings - Fork 1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add support for typed argument values #72
Comments
Initial implementation may simply be a convenience macro, something like let num = value_t!(matches.value_of("length"), u32); This would allow far more types initially simply using Rust's What's unclear is if failure to parse should constitute ending the process? I'm leaning towards returning an The other nice thing about a macro initially is I could potentially include something like a |
Adds convenience macros to get typed values Closes #72
While this isn't the best solution, it does work for the time being. I'm still unsure how to best implement this in a way that is least taxing on the developer (i.e. I don't want to force people to implement custom traits, or anything like that...) So this will remain TBD, but for now |
Initially support
Int
, andFloat
. Implementation should allow additions down the road as well, based on usage, maybe aFile
orDirectory
too...The text was updated successfully, but these errors were encountered: