Change ty.kind to a method

This commit is contained in:
LeSeulArtichaut
2020-08-03 00:49:11 +02:00
parent ef55a0a92f
commit 3e14b684dd
189 changed files with 947 additions and 899 deletions

View File

@@ -70,7 +70,7 @@ impl<'mir, 'tcx> Search<'mir, 'tcx> {
let param_env = tcx.param_env(def_id);
let func_ty = func.ty(body, tcx);
if let ty::FnDef(fn_def_id, substs) = func_ty.kind {
if let ty::FnDef(fn_def_id, substs) = *func_ty.kind() {
let (call_fn_id, call_substs) =
if let Ok(Some(instance)) = Instance::resolve(tcx, param_env, fn_def_id, substs) {
(instance.def_id(), instance.substs)