core: ndarray_from_ndlist_impl cast size_of to usize
This commit is contained in:
parent
83154ef8e1
commit
d6565feed3
@ -739,6 +739,8 @@ fn ndarray_from_ndlist_impl<'ctx, G: CodeGenerator + ?Sized>(
|
|||||||
_ => {
|
_ => {
|
||||||
let lst_len = src_lst.load_size(ctx, None);
|
let lst_len = src_lst.load_size(ctx, None);
|
||||||
let sizeof_elem = ctx.get_llvm_type(generator, elem_ty).size_of().unwrap();
|
let sizeof_elem = ctx.get_llvm_type(generator, elem_ty).size_of().unwrap();
|
||||||
|
let sizeof_elem = ctx.builder.build_int_cast(sizeof_elem, llvm_usize, "").unwrap();
|
||||||
|
|
||||||
let cpy_len = ctx
|
let cpy_len = ctx
|
||||||
.builder
|
.builder
|
||||||
.build_int_mul(
|
.build_int_mul(
|
||||||
|
Loading…
Reference in New Issue
Block a user