Skip to content

Commit

Permalink
Swapping to matches macro.
Browse files Browse the repository at this point in the history
  • Loading branch information
avborhanian committed Jun 8, 2023
1 parent 2f5d1c7 commit 20548eb
Showing 1 changed file with 1 addition and 4 deletions.
5 changes: 1 addition & 4 deletions clippy_lints/src/arc_with_non_send_sync.rs
Original file line number Diff line number Diff line change
Expand Up @@ -47,10 +47,7 @@ impl LateLintPass<'_> for ArcWithNonSendSync {
if let ExprKind::Path(func_path) = func.kind;
if last_path_segment(&func_path).ident.name == sym::new;
if let arg_ty = cx.typeck_results().expr_ty(arg);
if match arg_ty.kind() {
ty::Param(_) => false,
_ => true,
};
if !matches!(arg_ty.kind(), ty::Param(_));
if !cx.tcx
.lang_items()
.sync_trait()
Expand Down

0 comments on commit 20548eb

Please sign in to comment.