fix: clippy and format

This commit is contained in:
roife 2024-02-27 13:54:52 +08:00
parent ec5236f3a8
commit 76b86b24bd

View File

@ -417,8 +417,7 @@ fn inline(
let mut insert_let_stmt = || { let mut insert_let_stmt = || {
let param_ty = param_ty.clone().map(|param_ty| { let param_ty = param_ty.clone().map(|param_ty| {
if sema.hir_file_for(param_ty.syntax()).is_macro() { if sema.hir_file_for(param_ty.syntax()).is_macro() {
ast::Type::cast(insert_ws_into(param_ty.syntax().clone())) ast::Type::cast(insert_ws_into(param_ty.syntax().clone())).unwrap_or(param_ty)
.unwrap_or_else(|| param_ty)
} else { } else {
param_ty param_ty
} }