Stop using a depracated function

This commit is contained in:
bjorn3 2022-10-21 10:58:33 +00:00
parent da770abea3
commit b1791eef6a

View File

@ -348,7 +348,7 @@ pub(crate) fn new_var(
local: Local, local: Local,
layout: TyAndLayout<'tcx>, layout: TyAndLayout<'tcx>,
) -> CPlace<'tcx> { ) -> CPlace<'tcx> {
let var = Variable::with_u32(fx.next_ssa_var); let var = Variable::from_u32(fx.next_ssa_var);
fx.next_ssa_var += 1; fx.next_ssa_var += 1;
fx.bcx.declare_var(var, fx.clif_type(layout.ty).unwrap()); fx.bcx.declare_var(var, fx.clif_type(layout.ty).unwrap());
CPlace { inner: CPlaceInner::Var(local, var), layout } CPlace { inner: CPlaceInner::Var(local, var), layout }
@ -359,9 +359,9 @@ pub(crate) fn new_var_pair(
local: Local, local: Local,
layout: TyAndLayout<'tcx>, layout: TyAndLayout<'tcx>,
) -> CPlace<'tcx> { ) -> CPlace<'tcx> {
let var1 = Variable::with_u32(fx.next_ssa_var); let var1 = Variable::from_u32(fx.next_ssa_var);
fx.next_ssa_var += 1; fx.next_ssa_var += 1;
let var2 = Variable::with_u32(fx.next_ssa_var); let var2 = Variable::from_u32(fx.next_ssa_var);
fx.next_ssa_var += 1; fx.next_ssa_var += 1;
let (ty1, ty2) = fx.clif_pair_type(layout.ty).unwrap(); let (ty1, ty2) = fx.clif_pair_type(layout.ty).unwrap();