Skip to content
This repository was archived by the owner on May 28, 2025. It is now read-only.

Commit 83222f1

Browse files
committed
Sync from rust 34e6673
2 parents a45a81a + eb84167 commit 83222f1

File tree

5 files changed

+9
-9
lines changed

5 files changed

+9
-9
lines changed

src/abi/mod.rs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -420,9 +420,9 @@ pub(crate) fn codegen_terminator_call<'tcx>(
420420
};
421421

422422
let extra_args = &args[fn_sig.inputs().skip_binder().len()..];
423-
let extra_args = fx
424-
.tcx
425-
.mk_type_list(extra_args.iter().map(|op_arg| fx.monomorphize(op_arg.ty(fx.mir, fx.tcx))));
423+
let extra_args = fx.tcx.mk_type_list_from_iter(
424+
extra_args.iter().map(|op_arg| fx.monomorphize(op_arg.ty(fx.mir, fx.tcx))),
425+
);
426426
let fn_abi = if let Some(instance) = instance {
427427
RevealAllLayoutCx(fx.tcx).fn_abi_of_instance(instance, extra_args)
428428
} else {

src/codegen_i128.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ pub(crate) fn maybe_codegen<'tcx>(
4141
fx.layout_of(if is_signed { fx.tcx.types.i128 } else { fx.tcx.types.u128 }),
4242
))
4343
} else {
44-
let out_ty = fx.tcx.intern_tup(&[lhs.layout().ty, fx.tcx.types.bool]);
44+
let out_ty = fx.tcx.mk_tup(&[lhs.layout().ty, fx.tcx.types.bool]);
4545
let oflow = CPlace::new_stack_slot(fx, fx.layout_of(fx.tcx.types.i32));
4646
let lhs = lhs.load_scalar(fx);
4747
let rhs = rhs.load_scalar(fx);
@@ -63,7 +63,7 @@ pub(crate) fn maybe_codegen<'tcx>(
6363
}
6464
BinOp::Add | BinOp::Sub | BinOp::Mul => {
6565
assert!(checked);
66-
let out_ty = fx.tcx.intern_tup(&[lhs.layout().ty, fx.tcx.types.bool]);
66+
let out_ty = fx.tcx.mk_tup(&[lhs.layout().ty, fx.tcx.types.bool]);
6767
let out_place = CPlace::new_stack_slot(fx, fx.layout_of(out_ty));
6868
let param_types = vec![
6969
AbiParam::special(fx.pointer_type, ArgumentPurpose::StructReturn),

src/intrinsics/llvm_x86.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -191,7 +191,7 @@ fn llvm_add_sub<'tcx>(
191191
// carry0 | carry1 -> carry or borrow respectively
192192
let cb_out = fx.bcx.ins().bor(cb0, cb1);
193193

194-
let layout = fx.layout_of(fx.tcx.intern_tup(&[fx.tcx.types.u8, fx.tcx.types.u64]));
194+
let layout = fx.layout_of(fx.tcx.mk_tup(&[fx.tcx.types.u8, fx.tcx.types.u64]));
195195
let val = CValue::by_val_pair(cb_out, c, layout);
196196
ret.write_cvalue(fx, val);
197197
}

src/main_shim.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -119,7 +119,7 @@ pub(crate) fn maybe_create_entry_wrapper(
119119
tcx,
120120
ParamEnv::reveal_all(),
121121
report.def_id,
122-
tcx.intern_substs(&[GenericArg::from(main_ret_ty)]),
122+
tcx.mk_substs(&[GenericArg::from(main_ret_ty)]),
123123
)
124124
.unwrap()
125125
.unwrap()
@@ -146,7 +146,7 @@ pub(crate) fn maybe_create_entry_wrapper(
146146
tcx,
147147
ParamEnv::reveal_all(),
148148
start_def_id,
149-
tcx.intern_substs(&[main_ret_ty.into()]),
149+
tcx.mk_substs(&[main_ret_ty.into()]),
150150
)
151151
.unwrap()
152152
.unwrap()

src/num.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -289,7 +289,7 @@ pub(crate) fn codegen_checked_int_binop<'tcx>(
289289
_ => bug!("binop {:?} on checked int/uint lhs: {:?} rhs: {:?}", bin_op, in_lhs, in_rhs),
290290
};
291291

292-
let out_layout = fx.layout_of(fx.tcx.intern_tup(&[in_lhs.layout().ty, fx.tcx.types.bool]));
292+
let out_layout = fx.layout_of(fx.tcx.mk_tup(&[in_lhs.layout().ty, fx.tcx.types.bool]));
293293
CValue::by_val_pair(res, has_overflow, out_layout)
294294
}
295295

0 commit comments

Comments
 (0)