resolve clippy::invalid_paths on bool::then

This commit is contained in:
Kisaragi Marine 2024-06-20 11:18:25 +09:00
parent 4aee08f999
commit 9749d990ed
No known key found for this signature in database
GPG key ID: C6631564CD2110E4
2 changed files with 1 additions and 1 deletions

View file

@ -69,6 +69,7 @@ pub fn check_path(cx: &LateContext<'_>, path: &[&str]) -> bool {
SimplifiedType::Float(FloatTy::F64),
SimplifiedType::Slice,
SimplifiedType::Str,
SimplifiedType::Bool,
]
.iter()
.flat_map(|&ty| cx.tcx.incoherent_impls(ty).into_iter())

View file

@ -110,5 +110,4 @@ pub const VEC_POP: [&str; 4] = ["alloc", "vec", "Vec", "pop"];
pub const WAKER: [&str; 4] = ["core", "task", "wake", "Waker"];
pub const OPTION_UNWRAP: [&str; 4] = ["core", "option", "Option", "unwrap"];
pub const OPTION_EXPECT: [&str; 4] = ["core", "option", "Option", "expect"];
#[expect(clippy::invalid_paths)] // not sure why it thinks this, it works so
pub const BOOL_THEN: [&str; 4] = ["core", "bool", "<impl bool>", "then"];