diff options
| author | gingerBill <bill@gingerbill.org> | 2022-08-09 15:36:18 +0100 |
|---|---|---|
| committer | gingerBill <bill@gingerbill.org> | 2022-08-09 15:36:18 +0100 |
| commit | cb0a59bb2cfdeb971e88f329f07783ba1f93a5c9 (patch) | |
| tree | 1996d06dc99ef64112515cb4bd3e0a3853850f9f /src/llvm_backend_utility.cpp | |
| parent | 076700bd226aa620e8f6c45e6d9ad5a660299144 (diff) | |
Eliminate use of LLVMGetElementType for pointers
Diffstat (limited to 'src/llvm_backend_utility.cpp')
| -rw-r--r-- | src/llvm_backend_utility.cpp | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/src/llvm_backend_utility.cpp b/src/llvm_backend_utility.cpp index b6589a080..665ba1553 100644 --- a/src/llvm_backend_utility.cpp +++ b/src/llvm_backend_utility.cpp @@ -96,9 +96,7 @@ LLVMValueRef lb_mem_zero_ptr_internal(lbProcedure *p, LLVMValueRef ptr, LLVMValu args[2] = LLVMBuildIntCast2(p->builder, len, types[1], /*signed*/false, ""); // We always get the function pointer type rather than the function and there is apparently no way around that? - LLVMTypeRef type = lb_type(p->module, pr.type); - - type = lb_llvm_get_pointer_type(type); + LLVMTypeRef type = lb_type_internal_for_procedures_raw(p->module, pr.type); return LLVMBuildCall2(p->builder, type, pr.value, args, gb_count_of(args), ""); } |