You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Even though the docs says "using the same test", the predicate is changed in the second example (probably because otherwise it would not pass the assertion).
Please complete the following tasks
Rust Version
rustc 1.69.0 (84c898d65 2023-04-16)
Clap Version
4.2.2 (also confirmed present in master)
Minimal reproducible code
Not applicable.
Steps to reproduce the bug with the above code
Arg::default_value_if
.Actual Behaviour
The predicate used in the first example doesn't actually do anything, as it sets the default value regardless of whether the flag is passed.
Expected Behaviour
Should use the same predicate as the second example:
Additional Context
No response
Debug Output
No response
The text was updated successfully, but these errors were encountered: