Skip to content

Commit

Permalink
Auto merge of #12965 - KisaragiEffective:resolve-invalid-paths-on-boo…
Browse files Browse the repository at this point in the history
…l-then, r=blyxyas

resolve `clippy::invalid_paths` on `bool::then`

*Please write a short comment explaining your change (or "none" for internal only changes)*

changelog: none
  • Loading branch information
bors committed Jun 22, 2024
2 parents 0ce07f6 + 9749d99 commit 26c556d
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 1 deletion.
1 change: 1 addition & 0 deletions clippy_lints/src/utils/internal_lints/invalid_paths.rs
Original file line number Diff line number Diff line change
Expand Up @@ -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())
Expand Down
1 change: 0 additions & 1 deletion clippy_utils/src/paths.rs
Original file line number Diff line number Diff line change
Expand Up @@ -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"];

0 comments on commit 26c556d

Please sign in to comment.