mirror of
https://github.com/vlang/v.git
synced 2023-08-10 21:13:21 +03:00
dadf147382
It's very often that someone will need to process values that were not provided separately (eg. generating a complex default value like in V). This commit allows the user to call the *_opt() functions instead of forcing them to provide some magical default values. * flag: Implement int_multi(), float_multi() and string_multi() These 3 functions are useful when the application expects a flag to be repeated more than once. A sample would be: v -cflags someflag -cflags secondflag This feature exposes the raw array that the flag parser internally keeps and allow the application to parse it however they want instead of dropping everything except the first element. * flag: Add documentation Add comments describing what *_opt() and *_multi() do. |
||
---|---|---|
.. | ||
flag_test.v | ||
flag.v |