mirror of
https://github.com/rust-lang/rust-clippy
synced 2024-12-01 00:49:30 +00:00
Properly deprecate panic_params lint
This commit is contained in:
parent
113c1476c9
commit
dd4e471b3f
5 changed files with 17 additions and 8 deletions
|
@ -181,3 +181,8 @@ declare_deprecated_lint! {
|
|||
pub TEMPORARY_CSTRING_AS_PTR,
|
||||
"this lint has been uplifted to rustc and is now called `temporary_cstring_as_ptr`"
|
||||
}
|
||||
|
||||
declare_deprecated_lint! {
|
||||
pub PANIC_PARAMS,
|
||||
"this lint has been uplifted to rustc and is now called `panic_fmt`"
|
||||
}
|
||||
|
|
|
@ -495,6 +495,10 @@ pub fn register_plugins(store: &mut rustc_lint::LintStore, sess: &Session, conf:
|
|||
"clippy::temporary_cstring_as_ptr",
|
||||
"this lint has been uplifted to rustc and is now called `temporary_cstring_as_ptr`",
|
||||
);
|
||||
store.register_removed(
|
||||
"clippy::panic_params",
|
||||
"this lint has been uplifted to rustc and is now called `panic_fmt`",
|
||||
);
|
||||
// end deprecated lints, do not remove this comment, it’s used in `update_lints`
|
||||
|
||||
// begin register lints, do not remove this comment, it’s used in `update_lints`
|
||||
|
|
|
@ -1831,13 +1831,6 @@ vec![
|
|||
deprecation: None,
|
||||
module: "panic_in_result_fn",
|
||||
},
|
||||
Lint {
|
||||
name: "panic_params",
|
||||
group: "style",
|
||||
desc: "missing parameters in `panic!` calls",
|
||||
deprecation: None,
|
||||
module: "panic_unimplemented",
|
||||
},
|
||||
Lint {
|
||||
name: "panicking_unwrap",
|
||||
group: "correctness",
|
||||
|
|
|
@ -10,5 +10,6 @@
|
|||
#[warn(clippy::regex_macro)]
|
||||
#[warn(clippy::drop_bounds)]
|
||||
#[warn(clippy::temporary_cstring_as_ptr)]
|
||||
#[warn(clippy::panic_params)]
|
||||
|
||||
fn main() {}
|
||||
|
|
|
@ -72,11 +72,17 @@ error: lint `clippy::temporary_cstring_as_ptr` has been removed: `this lint has
|
|||
LL | #[warn(clippy::temporary_cstring_as_ptr)]
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
|
||||
error: lint `clippy::panic_params` has been removed: `this lint has been uplifted to rustc and is now called `panic_fmt``
|
||||
--> $DIR/deprecated.rs:13:8
|
||||
|
|
||||
LL | #[warn(clippy::panic_params)]
|
||||
| ^^^^^^^^^^^^^^^^^^^^
|
||||
|
||||
error: lint `clippy::str_to_string` has been removed: `using `str::to_string` is common even today and specialization will likely happen soon`
|
||||
--> $DIR/deprecated.rs:1:8
|
||||
|
|
||||
LL | #[warn(clippy::str_to_string)]
|
||||
| ^^^^^^^^^^^^^^^^^^^^^
|
||||
|
||||
error: aborting due to 13 previous errors
|
||||
error: aborting due to 14 previous errors
|
||||
|
||||
|
|
Loading…
Reference in a new issue