Skip to content

Commit 7ba9e99

Browse files
committed
Add support for mir::TerminatorKind::TailCall in clippy
1 parent b3455d2 commit 7ba9e99

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

src/tools/clippy/clippy_utils/src/qualify_min_const_fn.rs

+3-2
Original file line numberDiff line numberDiff line change
@@ -285,15 +285,16 @@ fn check_terminator<'tcx>(
285285
Err((span, "const fn generators are unstable".into()))
286286
},
287287

288-
TerminatorKind::Call {
288+
TerminatorKind::Call {
289289
func,
290290
args,
291291
call_source: _,
292292
destination: _,
293293
target: _,
294294
unwind: _,
295295
fn_span: _,
296-
} => {
296+
}
297+
| TerminatorKind::TailCall { func, args, fn_span: _ } => {
297298
let fn_ty = func.ty(body, tcx);
298299
if let ty::FnDef(fn_def_id, _) = *fn_ty.kind() {
299300
if !is_const_fn(tcx, fn_def_id, msrv) {

0 commit comments

Comments
 (0)