File tree Expand file tree Collapse file tree 1 file changed +3
-3
lines changed
src/tools/clippy/clippy_utils/src Expand file tree Collapse file tree 1 file changed +3
-3
lines changed Original file line number Diff line number Diff line change @@ -191,13 +191,13 @@ impl<'a> PanicExpn<'a> {
191191 if !macro_backtrace(expr.span).any(|macro_call| is_panic(cx, macro_call.def_id)) {
192192 return None;
193193 }
194- let ExprKind::Call(callee, [arg]) = expr.kind else { return None };
195- let ExprKind::Path(QPath::Resolved(_, path)) = callee.kind else { return None };
194+ let ExprKind::Call(callee, [arg]) = & expr.kind else { return None };
195+ let ExprKind::Path(QPath::Resolved(_, path)) = & callee.kind else { return None };
196196 let result = match path.segments.last().unwrap().ident.as_str() {
197197 "panic" if arg.span.ctxt() == expr.span.ctxt() => Self::Empty,
198198 "panic" | "panic_str" => Self::Str(arg),
199199 "panic_display" => {
200- let ExprKind::AddrOf(_, _, e) = arg.kind else { return None };
200+ let ExprKind::AddrOf(_, _, e) = & arg.kind else { return None };
201201 Self::Display(e)
202202 },
203203 "panic_fmt" => Self::Format(FormatArgsExpn::parse(cx, arg)?),
You can’t perform that action at this time.
0 commit comments