Skip to content

Commit 03f584c

Browse files
committed
Update field names in is_float
1 parent 0d00eaf commit 03f584c

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

clippy_lints/src/misc.rs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -498,11 +498,11 @@ fn is_signum(cx: &LateContext<'_, '_>, expr: &Expr<'_>) -> bool {
498498
false
499499
}
500500

501-
fn is_float(cx: &LateContext<'_, '_>, expr: &Expr) -> bool {
502-
let value = &walk_ptrs_ty(cx.tables.expr_ty(expr)).sty;
501+
fn is_float(cx: &LateContext<'_, '_>, expr: &Expr<'_>) -> bool {
502+
let value = &walk_ptrs_ty(cx.tables.expr_ty(expr)).kind;
503503

504504
if let ty::Array(arr_ty, _) = value {
505-
return matches!(arr_ty.sty, ty::Float(_));
505+
return matches!(arr_ty.kind, ty::Float(_));
506506
};
507507

508508
matches!(value, ty::Float(_))

0 commit comments

Comments
 (0)