Skip to content

Commit e91f5b2

Browse files
committed
Update field names in is_float
1 parent b53bcc7 commit e91f5b2

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
@@ -500,11 +500,11 @@ fn is_signum(cx: &LateContext<'_, '_>, expr: &Expr<'_>) -> bool {
500500
false
501501
}
502502

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

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

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

0 commit comments

Comments
 (0)