Ignore store undef calls

This commit is contained in:
gingerBill
2023-10-29 20:43:02 +00:00
parent f54a026acc
commit d589914956

View File

@@ -962,8 +962,12 @@ gb_internal bool lb_is_type_proc_recursive(Type *t) {
gb_internal void lb_emit_store(lbProcedure *p, lbValue ptr, lbValue value) {
GB_ASSERT(value.value != nullptr);
Type *a = type_deref(ptr.type);
if (LLVMIsUndef(value.value)) {
return;
}
Type *a = type_deref(ptr.type);
if (LLVMIsNull(value.value)) {
LLVMTypeRef src_t = llvm_addr_type(p->module, ptr);
if (is_type_proc(a)) {