mirror of
https://github.com/clap-rs/clap
synced 2024-12-13 22:32:33 +00:00
fix!: Remove SubCommand
This commit is contained in:
parent
99d92c916c
commit
da5d5b8b53
1 changed files with 0 additions and 26 deletions
26
src/lib.rs
26
src/lib.rs
|
@ -174,29 +174,3 @@ mod util;
|
|||
const INTERNAL_ERROR_MSG: &str = "Fatal internal error. Please consider filing a bug \
|
||||
report at https://github.com/clap-rs/clap/issues";
|
||||
const INVALID_UTF8: &str = "unexpected invalid UTF-8 code point";
|
||||
|
||||
/// Deprecated, replaced with [`Command::new`], unless you were looking for [Subcommand]
|
||||
#[cfg_attr(
|
||||
feature = "deprecated",
|
||||
deprecated(
|
||||
since = "3.0.0",
|
||||
note = "Replaced with `Command::new` unless you intended the `Subcommand` trait"
|
||||
)
|
||||
)]
|
||||
#[doc(hidden)]
|
||||
#[derive(Debug, Copy, Clone)]
|
||||
pub struct SubCommand {}
|
||||
|
||||
#[allow(deprecated)]
|
||||
impl SubCommand {
|
||||
/// Deprecated, replaced with [`Command::new`].
|
||||
/// Did you mean Subcommand (lower-case c)?
|
||||
#[cfg_attr(
|
||||
feature = "deprecated",
|
||||
deprecated(since = "3.0.0", note = "Replaced with `Command::new`")
|
||||
)]
|
||||
#[doc(hidden)]
|
||||
pub fn with_name<'help>(name: &str) -> App<'help> {
|
||||
Command::new(name)
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue