Skip to content

Commit 85e449a

Browse files
committed
Auto merge of #122852 - compiler-errors:raw-ptr, r=lcnr
Remove `TypeAndMut` from `ty::RawPtr` variant, make it take `Ty` and `Mutability` Pretty much mechanically converting `ty::RawPtr(ty::TypeAndMut { ty, mutbl })` to `ty::RawPtr(ty, mutbl)` and its fallout. r? lcnr cc rust-lang/types-team#124
2 parents b3df0d7 + 6a40dab commit 85e449a

File tree

126 files changed

+410
-579
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

126 files changed

+410
-579
lines changed

compiler/rustc_borrowck/src/diagnostics/mod.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -366,7 +366,7 @@ impl<'cx, 'tcx> MirBorrowckCtxt<'cx, 'tcx> {
366366
Some(variant.fields[field].name.to_string())
367367
}
368368
ty::Tuple(_) => Some(field.index().to_string()),
369-
ty::Ref(_, ty, _) | ty::RawPtr(ty::TypeAndMut { ty, .. }) => {
369+
ty::Ref(_, ty, _) | ty::RawPtr(ty, _) => {
370370
self.describe_field_from_ty(ty, field, variant_index, including_tuple_field)
371371
}
372372
ty::Array(ty, _) | ty::Slice(ty) => {

compiler/rustc_borrowck/src/diagnostics/region_errors.rs

+3-3
Original file line numberDiff line numberDiff line change
@@ -503,10 +503,10 @@ impl<'a, 'tcx> MirBorrowckCtxt<'a, 'tcx> {
503503
ty::VarianceDiagInfo::None => {}
504504
ty::VarianceDiagInfo::Invariant { ty, param_index } => {
505505
let (desc, note) = match ty.kind() {
506-
ty::RawPtr(ty_mut) => {
507-
assert_eq!(ty_mut.mutbl, rustc_hir::Mutability::Mut);
506+
ty::RawPtr(ty, mutbl) => {
507+
assert_eq!(*mutbl, rustc_hir::Mutability::Mut);
508508
(
509-
format!("a mutable pointer to `{}`", ty_mut.ty),
509+
format!("a mutable pointer to `{}`", ty),
510510
"mutable pointers are invariant over their type parameter".to_string(),
511511
)
512512
}

compiler/rustc_borrowck/src/diagnostics/region_name.rs

+2-2
Original file line numberDiff line numberDiff line change
@@ -555,8 +555,8 @@ impl<'tcx> MirBorrowckCtxt<'_, 'tcx> {
555555
search_stack.push((*elem_ty, elem_hir_ty));
556556
}
557557

558-
(ty::RawPtr(mut_ty), hir::TyKind::Ptr(mut_hir_ty)) => {
559-
search_stack.push((mut_ty.ty, &mut_hir_ty.ty));
558+
(ty::RawPtr(mut_ty, _), hir::TyKind::Ptr(mut_hir_ty)) => {
559+
search_stack.push((*mut_ty, &mut_hir_ty.ty));
560560
}
561561

562562
_ => {

compiler/rustc_borrowck/src/lib.rs

+3-3
Original file line numberDiff line numberDiff line change
@@ -1649,7 +1649,7 @@ impl<'cx, 'tcx> MirBorrowckCtxt<'cx, 'tcx> {
16491649
| ty::Str
16501650
| ty::Array(_, _)
16511651
| ty::Slice(_)
1652-
| ty::RawPtr(_)
1652+
| ty::RawPtr(_, _)
16531653
| ty::Ref(_, _, _)
16541654
| ty::FnDef(_, _)
16551655
| ty::FnPtr(_)
@@ -2284,8 +2284,8 @@ impl<'cx, 'tcx> MirBorrowckCtxt<'cx, 'tcx> {
22842284
}
22852285
}
22862286
}
2287-
ty::RawPtr(tnm) => {
2288-
match tnm.mutbl {
2287+
ty::RawPtr(_, mutbl) => {
2288+
match mutbl {
22892289
// `*const` raw pointers are not mutable
22902290
hir::Mutability::Not => Err(place),
22912291
// `*mut` raw pointers are always mutable, regardless of

compiler/rustc_borrowck/src/type_check/mod.rs

+8-15
Original file line numberDiff line numberDiff line change
@@ -2157,15 +2157,12 @@ impl<'a, 'tcx> TypeChecker<'a, 'tcx> {
21572157
}
21582158

21592159
CastKind::PointerCoercion(PointerCoercion::MutToConstPointer) => {
2160-
let ty::RawPtr(ty::TypeAndMut { ty: ty_from, mutbl: hir::Mutability::Mut }) =
2161-
op.ty(body, tcx).kind()
2160+
let ty::RawPtr(ty_from, hir::Mutability::Mut) = op.ty(body, tcx).kind()
21622161
else {
21632162
span_mirbug!(self, rvalue, "unexpected base type for cast {:?}", ty,);
21642163
return;
21652164
};
2166-
let ty::RawPtr(ty::TypeAndMut { ty: ty_to, mutbl: hir::Mutability::Not }) =
2167-
ty.kind()
2168-
else {
2165+
let ty::RawPtr(ty_to, hir::Mutability::Not) = ty.kind() else {
21692166
span_mirbug!(self, rvalue, "unexpected target type for cast {:?}", ty,);
21702167
return;
21712168
};
@@ -2190,12 +2187,10 @@ impl<'a, 'tcx> TypeChecker<'a, 'tcx> {
21902187
let ty_from = op.ty(body, tcx);
21912188

21922189
let opt_ty_elem_mut = match ty_from.kind() {
2193-
ty::RawPtr(ty::TypeAndMut { mutbl: array_mut, ty: array_ty }) => {
2194-
match array_ty.kind() {
2195-
ty::Array(ty_elem, _) => Some((ty_elem, *array_mut)),
2196-
_ => None,
2197-
}
2198-
}
2190+
ty::RawPtr(array_ty, array_mut) => match array_ty.kind() {
2191+
ty::Array(ty_elem, _) => Some((ty_elem, *array_mut)),
2192+
_ => None,
2193+
},
21992194
_ => None,
22002195
};
22012196

@@ -2210,9 +2205,7 @@ impl<'a, 'tcx> TypeChecker<'a, 'tcx> {
22102205
};
22112206

22122207
let (ty_to, ty_to_mut) = match ty.kind() {
2213-
ty::RawPtr(ty::TypeAndMut { mutbl: ty_to_mut, ty: ty_to }) => {
2214-
(ty_to, *ty_to_mut)
2215-
}
2208+
ty::RawPtr(ty_to, ty_to_mut) => (ty_to, *ty_to_mut),
22162209
_ => {
22172210
span_mirbug!(
22182211
self,
@@ -2413,7 +2406,7 @@ impl<'a, 'tcx> TypeChecker<'a, 'tcx> {
24132406
let ty_left = left.ty(body, tcx);
24142407
match ty_left.kind() {
24152408
// Types with regions are comparable if they have a common super-type.
2416-
ty::RawPtr(_) | ty::FnPtr(_) => {
2409+
ty::RawPtr(_, _) | ty::FnPtr(_) => {
24172410
let ty_right = right.ty(body, tcx);
24182411
let common_ty = self.infcx.next_ty_var(TypeVariableOrigin {
24192412
kind: TypeVariableOriginKind::MiscVariable,

compiler/rustc_codegen_cranelift/src/abi/mod.rs

+1-5
Original file line numberDiff line numberDiff line change
@@ -677,11 +677,7 @@ pub(crate) fn codegen_drop<'tcx>(
677677

678678
let arg_value = drop_place.place_ref(
679679
fx,
680-
fx.layout_of(Ty::new_ref(
681-
fx.tcx,
682-
fx.tcx.lifetimes.re_erased,
683-
TypeAndMut { ty, mutbl: crate::rustc_hir::Mutability::Mut },
684-
)),
680+
fx.layout_of(Ty::new_mut_ref(fx.tcx, fx.tcx.lifetimes.re_erased, ty)),
685681
);
686682
let arg_value = adjust_arg_for_abi(fx, arg_value, &fn_abi.args[0], true);
687683

compiler/rustc_codegen_cranelift/src/common.rs

+2-2
Original file line numberDiff line numberDiff line change
@@ -69,7 +69,7 @@ fn clif_type_from_ty<'tcx>(tcx: TyCtxt<'tcx>, ty: Ty<'tcx>) -> Option<types::Typ
6969
FloatTy::F128 => unimplemented!("f16_f128"),
7070
},
7171
ty::FnPtr(_) => pointer_ty(tcx),
72-
ty::RawPtr(TypeAndMut { ty: pointee_ty, mutbl: _ }) | ty::Ref(_, pointee_ty, _) => {
72+
ty::RawPtr(pointee_ty, _) | ty::Ref(_, pointee_ty, _) => {
7373
if has_ptr_meta(tcx, *pointee_ty) {
7474
return None;
7575
} else {
@@ -89,7 +89,7 @@ fn clif_pair_type_from_ty<'tcx>(
8989
ty::Tuple(types) if types.len() == 2 => {
9090
(clif_type_from_ty(tcx, types[0])?, clif_type_from_ty(tcx, types[1])?)
9191
}
92-
ty::RawPtr(TypeAndMut { ty: pointee_ty, mutbl: _ }) | ty::Ref(_, pointee_ty, _) => {
92+
ty::RawPtr(pointee_ty, _) | ty::Ref(_, pointee_ty, _) => {
9393
if has_ptr_meta(tcx, *pointee_ty) {
9494
(pointer_ty(tcx), pointer_ty(tcx))
9595
} else {

compiler/rustc_codegen_cranelift/src/unsize.rs

+2-4
Original file line numberDiff line numberDiff line change
@@ -70,10 +70,8 @@ fn unsize_ptr<'tcx>(
7070
) -> (Value, Value) {
7171
match (&src_layout.ty.kind(), &dst_layout.ty.kind()) {
7272
(&ty::Ref(_, a, _), &ty::Ref(_, b, _))
73-
| (&ty::Ref(_, a, _), &ty::RawPtr(ty::TypeAndMut { ty: b, .. }))
74-
| (&ty::RawPtr(ty::TypeAndMut { ty: a, .. }), &ty::RawPtr(ty::TypeAndMut { ty: b, .. })) => {
75-
(src, unsized_info(fx, *a, *b, old_info))
76-
}
73+
| (&ty::Ref(_, a, _), &ty::RawPtr(b, _))
74+
| (&ty::RawPtr(a, _), &ty::RawPtr(b, _)) => (src, unsized_info(fx, *a, *b, old_info)),
7775
(&ty::Adt(def_a, _), &ty::Adt(def_b, _)) => {
7876
assert_eq!(def_a, def_b);
7977

compiler/rustc_codegen_cranelift/src/value_and_place.rs

+2-7
Original file line numberDiff line numberDiff line change
@@ -865,15 +865,10 @@ pub(crate) fn assert_assignable<'tcx>(
865865
return;
866866
}
867867
match (from_ty.kind(), to_ty.kind()) {
868-
(ty::Ref(_, a, _), ty::Ref(_, b, _))
869-
| (
870-
ty::RawPtr(TypeAndMut { ty: a, mutbl: _ }),
871-
ty::RawPtr(TypeAndMut { ty: b, mutbl: _ }),
872-
) => {
868+
(ty::Ref(_, a, _), ty::Ref(_, b, _)) | (ty::RawPtr(a, _), ty::RawPtr(b, _)) => {
873869
assert_assignable(fx, *a, *b, limit - 1);
874870
}
875-
(ty::Ref(_, a, _), ty::RawPtr(TypeAndMut { ty: b, mutbl: _ }))
876-
| (ty::RawPtr(TypeAndMut { ty: a, mutbl: _ }), ty::Ref(_, b, _)) => {
871+
(ty::Ref(_, a, _), ty::RawPtr(b, _)) | (ty::RawPtr(a, _), ty::Ref(_, b, _)) => {
877872
assert_assignable(fx, *a, *b, limit - 1);
878873
}
879874
(ty::FnPtr(_), ty::FnPtr(_)) => {

compiler/rustc_codegen_gcc/src/intrinsic/simd.rs

+12-12
Original file line numberDiff line numberDiff line change
@@ -796,16 +796,16 @@ pub fn generic_simd_intrinsic<'a, 'gcc, 'tcx>(
796796

797797
// This counts how many pointers
798798
fn ptr_count(t: Ty<'_>) -> usize {
799-
match t.kind() {
800-
ty::RawPtr(p) => 1 + ptr_count(p.ty),
799+
match *t.kind() {
800+
ty::RawPtr(p_ty, _) => 1 + ptr_count(p_ty),
801801
_ => 0,
802802
}
803803
}
804804

805805
// Non-ptr type
806806
fn non_ptr(t: Ty<'_>) -> Ty<'_> {
807-
match t.kind() {
808-
ty::RawPtr(p) => non_ptr(p.ty),
807+
match *t.kind() {
808+
ty::RawPtr(p_ty, _) => non_ptr(p_ty),
809809
_ => t,
810810
}
811811
}
@@ -814,8 +814,8 @@ pub fn generic_simd_intrinsic<'a, 'gcc, 'tcx>(
814814
// to the element type of the first argument
815815
let (_, element_ty0) = arg_tys[0].simd_size_and_type(bx.tcx());
816816
let (_, element_ty1) = arg_tys[1].simd_size_and_type(bx.tcx());
817-
let (pointer_count, underlying_ty) = match element_ty1.kind() {
818-
ty::RawPtr(p) if p.ty == in_elem => (ptr_count(element_ty1), non_ptr(element_ty1)),
817+
let (pointer_count, underlying_ty) = match *element_ty1.kind() {
818+
ty::RawPtr(p_ty, _) if p_ty == in_elem => (ptr_count(element_ty1), non_ptr(element_ty1)),
819819
_ => {
820820
require!(
821821
false,
@@ -910,16 +910,16 @@ pub fn generic_simd_intrinsic<'a, 'gcc, 'tcx>(
910910

911911
// This counts how many pointers
912912
fn ptr_count(t: Ty<'_>) -> usize {
913-
match t.kind() {
914-
ty::RawPtr(p) => 1 + ptr_count(p.ty),
913+
match *t.kind() {
914+
ty::RawPtr(p_ty, _) => 1 + ptr_count(p_ty),
915915
_ => 0,
916916
}
917917
}
918918

919919
// Non-ptr type
920920
fn non_ptr(t: Ty<'_>) -> Ty<'_> {
921-
match t.kind() {
922-
ty::RawPtr(p) => non_ptr(p.ty),
921+
match *t.kind() {
922+
ty::RawPtr(p_ty, _) => non_ptr(p_ty),
923923
_ => t,
924924
}
925925
}
@@ -929,8 +929,8 @@ pub fn generic_simd_intrinsic<'a, 'gcc, 'tcx>(
929929
let (_, element_ty0) = arg_tys[0].simd_size_and_type(bx.tcx());
930930
let (_, element_ty1) = arg_tys[1].simd_size_and_type(bx.tcx());
931931
let (_, element_ty2) = arg_tys[2].simd_size_and_type(bx.tcx());
932-
let (pointer_count, underlying_ty) = match element_ty1.kind() {
933-
ty::RawPtr(p) if p.ty == in_elem && p.mutbl == hir::Mutability::Mut => {
932+
let (pointer_count, underlying_ty) = match *element_ty1.kind() {
933+
ty::RawPtr(p_ty, mutbl) if p_ty == in_elem && mutbl == hir::Mutability::Mut => {
934934
(ptr_count(element_ty1), non_ptr(element_ty1))
935935
}
936936
_ => {

compiler/rustc_codegen_llvm/src/debuginfo/metadata.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -452,7 +452,7 @@ pub fn type_di_node<'ll, 'tcx>(cx: &CodegenCx<'ll, 'tcx>, t: Ty<'tcx>) -> &'ll D
452452
ty::Slice(_) | ty::Str => build_slice_type_di_node(cx, t, unique_type_id),
453453
ty::Dynamic(..) => build_dyn_type_di_node(cx, t, unique_type_id),
454454
ty::Foreign(..) => build_foreign_type_di_node(cx, t, unique_type_id),
455-
ty::RawPtr(ty::TypeAndMut { ty: pointee_type, .. }) | ty::Ref(_, pointee_type, _) => {
455+
ty::RawPtr(pointee_type, _) | ty::Ref(_, pointee_type, _) => {
456456
build_pointer_or_reference_di_node(cx, t, pointee_type, unique_type_id)
457457
}
458458
// Some `Box` are newtyped pointers, make debuginfo aware of that.

compiler/rustc_codegen_llvm/src/intrinsic.rs

+17-17
Original file line numberDiff line numberDiff line change
@@ -1483,7 +1483,7 @@ fn generic_simd_intrinsic<'ll, 'tcx>(
14831483
v.normalize(bx.target_spec().pointer_width).bit_width().unwrap()
14841484
),
14851485
ty::Float(v) => format!("v{}f{}", vec_len, v.bit_width()),
1486-
ty::RawPtr(_) => format!("v{}p0", vec_len),
1486+
ty::RawPtr(_, _) => format!("v{}p0", vec_len),
14871487
_ => unreachable!(),
14881488
}
14891489
}
@@ -1493,7 +1493,7 @@ fn generic_simd_intrinsic<'ll, 'tcx>(
14931493
ty::Int(v) => cx.type_int_from_ty(v),
14941494
ty::Uint(v) => cx.type_uint_from_ty(v),
14951495
ty::Float(v) => cx.type_float_from_ty(v),
1496-
ty::RawPtr(_) => cx.type_ptr(),
1496+
ty::RawPtr(_, _) => cx.type_ptr(),
14971497
_ => unreachable!(),
14981498
};
14991499
cx.type_vector(elem_ty, vec_len)
@@ -1548,8 +1548,8 @@ fn generic_simd_intrinsic<'ll, 'tcx>(
15481548

15491549
require!(
15501550
matches!(
1551-
element_ty1.kind(),
1552-
ty::RawPtr(p) if p.ty == in_elem && p.ty.kind() == element_ty0.kind()
1551+
*element_ty1.kind(),
1552+
ty::RawPtr(p_ty, _) if p_ty == in_elem && p_ty.kind() == element_ty0.kind()
15531553
),
15541554
InvalidMonomorphization::ExpectedElementType {
15551555
span,
@@ -1654,8 +1654,8 @@ fn generic_simd_intrinsic<'ll, 'tcx>(
16541654

16551655
require!(
16561656
matches!(
1657-
pointer_ty.kind(),
1658-
ty::RawPtr(p) if p.ty == values_elem && p.ty.kind() == values_elem.kind()
1657+
*pointer_ty.kind(),
1658+
ty::RawPtr(p_ty, _) if p_ty == values_elem && p_ty.kind() == values_elem.kind()
16591659
),
16601660
InvalidMonomorphization::ExpectedElementType {
16611661
span,
@@ -1746,8 +1746,8 @@ fn generic_simd_intrinsic<'ll, 'tcx>(
17461746
// The second argument must be a mutable pointer type matching the element type
17471747
require!(
17481748
matches!(
1749-
pointer_ty.kind(),
1750-
ty::RawPtr(p) if p.ty == values_elem && p.ty.kind() == values_elem.kind() && p.mutbl.is_mut()
1749+
*pointer_ty.kind(),
1750+
ty::RawPtr(p_ty, p_mutbl) if p_ty == values_elem && p_ty.kind() == values_elem.kind() && p_mutbl.is_mut()
17511751
),
17521752
InvalidMonomorphization::ExpectedElementType {
17531753
span,
@@ -1843,9 +1843,9 @@ fn generic_simd_intrinsic<'ll, 'tcx>(
18431843

18441844
require!(
18451845
matches!(
1846-
element_ty1.kind(),
1847-
ty::RawPtr(p)
1848-
if p.ty == in_elem && p.mutbl.is_mut() && p.ty.kind() == element_ty0.kind()
1846+
*element_ty1.kind(),
1847+
ty::RawPtr(p_ty, p_mutbl)
1848+
if p_ty == in_elem && p_mutbl.is_mut() && p_ty.kind() == element_ty0.kind()
18491849
),
18501850
InvalidMonomorphization::ExpectedElementType {
18511851
span,
@@ -2074,8 +2074,8 @@ fn generic_simd_intrinsic<'ll, 'tcx>(
20742074
);
20752075

20762076
match in_elem.kind() {
2077-
ty::RawPtr(p) => {
2078-
let metadata = p.ty.ptr_metadata_ty(bx.tcx, |ty| {
2077+
ty::RawPtr(p_ty, _) => {
2078+
let metadata = p_ty.ptr_metadata_ty(bx.tcx, |ty| {
20792079
bx.tcx.normalize_erasing_regions(ty::ParamEnv::reveal_all(), ty)
20802080
});
20812081
require!(
@@ -2088,8 +2088,8 @@ fn generic_simd_intrinsic<'ll, 'tcx>(
20882088
}
20892089
}
20902090
match out_elem.kind() {
2091-
ty::RawPtr(p) => {
2092-
let metadata = p.ty.ptr_metadata_ty(bx.tcx, |ty| {
2091+
ty::RawPtr(p_ty, _) => {
2092+
let metadata = p_ty.ptr_metadata_ty(bx.tcx, |ty| {
20932093
bx.tcx.normalize_erasing_regions(ty::ParamEnv::reveal_all(), ty)
20942094
});
20952095
require!(
@@ -2120,7 +2120,7 @@ fn generic_simd_intrinsic<'ll, 'tcx>(
21202120
);
21212121

21222122
match in_elem.kind() {
2123-
ty::RawPtr(_) => {}
2123+
ty::RawPtr(_, _) => {}
21242124
_ => {
21252125
return_error!(InvalidMonomorphization::ExpectedPointer { span, name, ty: in_elem })
21262126
}
@@ -2152,7 +2152,7 @@ fn generic_simd_intrinsic<'ll, 'tcx>(
21522152
_ => return_error!(InvalidMonomorphization::ExpectedUsize { span, name, ty: in_elem }),
21532153
}
21542154
match out_elem.kind() {
2155-
ty::RawPtr(_) => {}
2155+
ty::RawPtr(_, _) => {}
21562156
_ => {
21572157
return_error!(InvalidMonomorphization::ExpectedPointer { span, name, ty: out_elem })
21582158
}

compiler/rustc_codegen_ssa/src/base.rs

+2-2
Original file line numberDiff line numberDiff line change
@@ -193,8 +193,8 @@ pub fn unsize_ptr<'a, 'tcx, Bx: BuilderMethods<'a, 'tcx>>(
193193
) -> (Bx::Value, Bx::Value) {
194194
debug!("unsize_ptr: {:?} => {:?}", src_ty, dst_ty);
195195
match (src_ty.kind(), dst_ty.kind()) {
196-
(&ty::Ref(_, a, _), &ty::Ref(_, b, _) | &ty::RawPtr(ty::TypeAndMut { ty: b, .. }))
197-
| (&ty::RawPtr(ty::TypeAndMut { ty: a, .. }), &ty::RawPtr(ty::TypeAndMut { ty: b, .. })) => {
196+
(&ty::Ref(_, a, _), &ty::Ref(_, b, _) | &ty::RawPtr(b, _))
197+
| (&ty::RawPtr(a, _), &ty::RawPtr(b, _)) => {
198198
assert_eq!(bx.cx().type_is_sized(a), old_info.is_none());
199199
(src, unsized_info(bx, a, b, old_info))
200200
}

compiler/rustc_codegen_ssa/src/debuginfo/type_names.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -138,7 +138,7 @@ fn push_debuginfo_type_name<'tcx>(
138138
output.push(')');
139139
}
140140
}
141-
ty::RawPtr(ty::TypeAndMut { ty: inner_type, mutbl }) => {
141+
ty::RawPtr(inner_type, mutbl) => {
142142
if cpp_like_debuginfo {
143143
match mutbl {
144144
Mutability::Not => output.push_str("ptr_const$<"),

compiler/rustc_codegen_ssa/src/mir/debuginfo.rs

+1-4
Original file line numberDiff line numberDiff line change
@@ -414,10 +414,7 @@ impl<'a, 'tcx, Bx: BuilderMethods<'a, 'tcx>> FunctionCx<'a, 'tcx, Bx> {
414414
calculate_debuginfo_offset(bx, var.projection, base);
415415

416416
// Create a variable which will be a pointer to the actual value
417-
let ptr_ty = Ty::new_ptr(
418-
bx.tcx(),
419-
ty::TypeAndMut { mutbl: mir::Mutability::Mut, ty: place.layout.ty },
420-
);
417+
let ptr_ty = Ty::new_mut_ptr(bx.tcx(), place.layout.ty);
421418
let ptr_layout = bx.layout_of(ptr_ty);
422419
let alloca = PlaceRef::alloca(bx, ptr_layout);
423420
bx.set_var_name(alloca.llval, &(var.name.to_string() + ".dbg.spill"));

0 commit comments

Comments
 (0)