mirror of
https://github.com/clap-rs/clap
synced 2024-12-13 22:32:33 +00:00
fix(parser): Process overrides with new Actions
This commit is contained in:
parent
55a705c447
commit
1abc945545
1 changed files with 4 additions and 0 deletions
|
@ -1563,6 +1563,10 @@ impl<'help, 'cmd> Parser<'help, 'cmd> {
|
||||||
}
|
}
|
||||||
|
|
||||||
fn start_custom_arg(&self, matcher: &mut ArgMatcher, arg: &Arg<'help>, source: ValueSource) {
|
fn start_custom_arg(&self, matcher: &mut ArgMatcher, arg: &Arg<'help>, source: ValueSource) {
|
||||||
|
if source == ValueSource::CommandLine {
|
||||||
|
// With each new occurrence, remove overrides from prior occurrences
|
||||||
|
self.remove_overrides(arg, matcher);
|
||||||
|
}
|
||||||
matcher.start_custom_arg(arg, source);
|
matcher.start_custom_arg(arg, source);
|
||||||
for group in self.cmd.groups_for_arg(&arg.id) {
|
for group in self.cmd.groups_for_arg(&arg.id) {
|
||||||
matcher.start_custom_group(&group, source);
|
matcher.start_custom_group(&group, source);
|
||||||
|
|
Loading…
Reference in a new issue