Use Level::from_symbol in unnecessary_clippy_cfg
This commit is contained in:
parent
6591dc683e
commit
cc6dcaae57
@ -1000,9 +1000,7 @@ fn check_clippy_cfg_attr(
|
||||
) {
|
||||
if cfg_attr.has_name(sym::clippy)
|
||||
&& let Some(ident) = behind_cfg_attr.ident()
|
||||
// FIXME: replace with `from_symbol` once https://github.com/rust-lang/rust/pull/121230
|
||||
// is merged.
|
||||
&& Level::from_str(ident.name.as_str()).is_some()
|
||||
&& Level::from_symbol(ident.name, Some(attr.id)).is_some()
|
||||
&& let Some(items) = behind_cfg_attr.meta_item_list()
|
||||
{
|
||||
let nb_items = items.len();
|
||||
|
Loading…
x
Reference in New Issue
Block a user