#[non_exhaustive]pub enum WarningKind {
DeprecatedFlag,
DeprecatedCommand,
DeprecatedEnv,
Other,
}Expand description
The kinds of deprecation a parse can run into.
The message is for a person and its wording is nobody’s contract; this is what a program can
act on. A CLI that queues its warnings wants to sort them; a --strict mode wants to refuse
one kind and not another; a conformance vector wants to pin what happened without pinning how
it was worded.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Non-exhaustive enums could have additional variants added in future. Therefore, when matching against variants of non-exhaustive enums, an extra wildcard arm must be added to account for any future variants.
DeprecatedFlag
A flag whose declaration says not to use it any more.
DeprecatedCommand
A command whose declaration says not to use it any more. Every deprecated command on the selected path reports, not only the last one.
DeprecatedEnv
A value that arrived through a deprecated_env alias rather than a current name.
Other
Something a CLI’s own layer says, which this crate has no name for.
Trait Implementations§
Source§impl Clone for WarningKind
impl Clone for WarningKind
Source§fn clone(&self) -> WarningKind
fn clone(&self) -> WarningKind
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreimpl Copy for WarningKind
Source§impl Debug for WarningKind
impl Debug for WarningKind
Source§impl Default for WarningKind
impl Default for WarningKind
Source§fn default() -> WarningKind
fn default() -> WarningKind
Returns the “default value” for a type. Read more
impl Eq for WarningKind
Source§impl PartialEq for WarningKind
impl PartialEq for WarningKind
impl StructuralPartialEq for WarningKind
Auto Trait Implementations§
impl Freeze for WarningKind
impl RefUnwindSafe for WarningKind
impl Send for WarningKind
impl Sync for WarningKind
impl Unpin for WarningKind
impl UnsafeUnpin for WarningKind
impl UnwindSafe for WarningKind
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more