Skip to content

Commit 384f71f

Browse files
committed
clap: Replace deprecated attribute #[clap(...)] with #[command(...)]
Fixes these warnings when running `cargo check --features clap/deprecated`: warning: use of deprecated function `<Cargo as clap::Subcommand>::augment_subcommands::old_attribute`: Attribute `#[clap(...)]` has been deprecated in favor of `#[command(...)]` --> src/main.rs:60:3 | 60 | #[clap(bin_name = "cargo", subcommand_required = true)] | ^^^^ | = note: `#[warn(deprecated)]` on by default warning: use of deprecated function `<Opts as clap::Args>::augment_args::old_attribute`: Attribute `#[clap(...)]` has been deprecated in favor of `#[command(...)]` --> src/main.rs:66:3 | 66 | #[clap( | ^^^^
1 parent 14e7edd commit 384f71f

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/main.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -57,13 +57,13 @@ const REPORT_HEADER: &str = "\
5757
==================================================================================";
5858

5959
#[derive(Debug, Parser)]
60-
#[clap(bin_name = "cargo", subcommand_required = true)]
60+
#[command(bin_name = "cargo", subcommand_required = true)]
6161
enum Cargo {
6262
BisectRustc(Opts),
6363
}
6464

6565
#[derive(Debug, Parser)]
66-
#[clap(
66+
#[command(
6767
bin_name = "cargo bisect-rustc",
6868
version,
6969
about,

0 commit comments

Comments
 (0)