fix: Remove EmptyValues

The intention had been to that people setting this would now set
nothing.  Unfortunately, clap2 had `EmptyValues` as the default, so
people were more likely to unset it, making this not work out.
This commit is contained in:
Ed Page 2021-12-02 09:58:47 -06:00
parent e751d5e372
commit 83abb24002

View file

@ -52,7 +52,6 @@ impl_settings! { ArgSettings, ArgFlags,
MultipleValues("multiplevalues") => Flags::MULTIPLE_VALS,
Multiple("multiple") => Flags::MULTIPLE,
ForbidEmptyValues("forbidemptyvalues") => Flags::NO_EMPTY_VALS,
EmptyValues("emptyvalues") => Flags::NO_OP,
Hidden("hidden") => Flags::HIDDEN,
TakesValue("takesvalue") => Flags::TAKES_VAL,
UseValueDelimiter("usevaluedelimiter") => Flags::USE_DELIM,
@ -100,13 +99,6 @@ pub enum ArgSettings {
Multiple,
/// Forbids an arg from accepting empty values such as `""`
ForbidEmptyValues,
/// Deprecated, this is now the default, see [`ArgSettings::ForbidEmptyValues`] for the
/// opposite.
#[deprecated(
since = "3.0.0",
note = "This is now the default see [`ArgSettings::ForbidEmptyValues`] for the opposite."
)]
EmptyValues,
/// Hides an arg from the help message
Hidden,
/// Allows an argument to take a value (such as `--option value`)