Open epage opened 2 years ago
Issue by epage Tuesday Nov 09, 2021 at 14:38 GMT Originally opened as https://github.com/clap-rs/clap/issues/3008
master
Define one or more App Validation trait
App
ArgMatches
Steps
default_value_if
Option
clap::validate
Arg
No response
See also https://github.com/clap-rs/clap/discussions/2832
Risks are usability and performance. The most basic APIs, like required, we probably need to keep baked in. Its the special inter-arg interactions that we should be focusing on.
required
Issue by epage Tuesday Nov 09, 2021 at 14:38 GMT Originally opened as https://github.com/clap-rs/clap/issues/3008
Please complete the following tasks
Clap Version
master
Describe your use case
Describe the solution you'd like
Define one or more App Validation trait
App
andArgMatches
as an input, reports errorsApp
,ArgMatches
, and args as input, reports which args are requiredApp
,ArgMatches
, and args as input, reports default values for themSteps
default_value_if
API with its use ofOption
by clarifying intent through buildersclap::validate
Arg
functions so now only those using this API pay the cost due to dead code eliminationAlternatives, if applicable
No response
Additional Context
See also https://github.com/clap-rs/clap/discussions/2832
Risks are usability and performance. The most basic APIs, like
required
, we probably need to keep baked in. Its the special inter-arg interactions that we should be focusing on.