We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
2 parents 66dd172 + 097c9c7 commit ed892e7Copy full SHA for ed892e7
clippy_utils/src/lib.rs
@@ -2363,14 +2363,14 @@ pub fn is_no_std_crate(cx: &LateContext<'_>) -> bool {
2363
cx.tcx
2364
.hir_attrs(hir::CRATE_HIR_ID)
2365
.iter()
2366
- .any(|attr| attr.name_or_empty() == sym::no_std)
+ .any(|attr| attr.has_name(sym::no_std))
2367
}
2368
2369
pub fn is_no_core_crate(cx: &LateContext<'_>) -> bool {
2370
2371
2372
2373
- .any(|attr| attr.name_or_empty() == sym::no_core)
+ .any(|attr| attr.has_name(sym::no_core))
2374
2375
2376
/// Check if parent of a hir node is a trait implementation block.
0 commit comments