Revert "Auto merge of #134330 - scottmcm:no-more-rvalue-len, r=matthewjasper"
This reverts commite108481f74
, reversing changes made to303e8bd768
.
This commit is contained in:
parent
14b00fba0a
commit
9acb9fa57b
1 changed files with 6 additions and 0 deletions
|
@ -828,6 +828,12 @@ fn codegen_stmt<'tcx>(
|
||||||
fx.bcx.ins().nop();
|
fx.bcx.ins().nop();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Rvalue::Len(place) => {
|
||||||
|
let place = codegen_place(fx, place);
|
||||||
|
let usize_layout = fx.layout_of(fx.tcx.types.usize);
|
||||||
|
let len = codegen_array_len(fx, place);
|
||||||
|
lval.write_cvalue(fx, CValue::by_val(len, usize_layout));
|
||||||
|
}
|
||||||
Rvalue::ShallowInitBox(ref operand, content_ty) => {
|
Rvalue::ShallowInitBox(ref operand, content_ty) => {
|
||||||
let content_ty = fx.monomorphize(content_ty);
|
let content_ty = fx.monomorphize(content_ty);
|
||||||
let box_layout = fx.layout_of(Ty::new_box(fx.tcx, content_ty));
|
let box_layout = fx.layout_of(Ty::new_box(fx.tcx, content_ty));
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue