diff options
| author | flip1995 <philipp.krones@embecosm.com> | 2022-01-13 13:37:24 +0100 |
|---|---|---|
| committer | flip1995 <philipp.krones@embecosm.com> | 2022-01-13 13:37:29 +0100 |
| commit | 7e267c23d64f8a6c72d0d71cce5284f70376ea13 (patch) | |
| tree | 17e54937046b4ca05155cc584eb0ba0c12313ea2 | |
| parent | fb0142ae41a49a4dda6bc0c7487efa00818c8f49 (diff) | |
| download | rust-7e267c23d64f8a6c72d0d71cce5284f70376ea13.tar.gz rust-7e267c23d64f8a6c72d0d71cce5284f70376ea13.zip | |
Fix Clippy sync fallout
| -rw-r--r-- | clippy_utils/src/macros.rs | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/clippy_utils/src/macros.rs b/clippy_utils/src/macros.rs index a3e336d701c..b7a242cf90a 100644 --- a/clippy_utils/src/macros.rs +++ b/clippy_utils/src/macros.rs @@ -191,13 +191,13 @@ impl<'a> PanicExpn<'a> { if !macro_backtrace(expr.span).any(|macro_call| is_panic(cx, macro_call.def_id)) { return None; } - let ExprKind::Call(callee, [arg]) = expr.kind else { return None }; - let ExprKind::Path(QPath::Resolved(_, path)) = callee.kind else { return None }; + let ExprKind::Call(callee, [arg]) = &expr.kind else { return None }; + let ExprKind::Path(QPath::Resolved(_, path)) = &callee.kind else { return None }; let result = match path.segments.last().unwrap().ident.as_str() { "panic" if arg.span.ctxt() == expr.span.ctxt() => Self::Empty, "panic" | "panic_str" => Self::Str(arg), "panic_display" => { - let ExprKind::AddrOf(_, _, e) = arg.kind else { return None }; + let ExprKind::AddrOf(_, _, e) = &arg.kind else { return None }; Self::Display(e) }, "panic_fmt" => Self::Format(FormatArgsExpn::parse(cx, arg)?), |
