aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorgingerBill <bill@gingerbill.org>2024-03-26 17:16:12 +0000
committergingerBill <bill@gingerbill.org>2024-03-26 17:16:12 +0000
commit63d6b4752bcbc5ca28adbd13ef91fee25d4f7465 (patch)
treeb691996cdd3345d8dbf3d36a43cebe12e85b0429
parent6588fe35b302118944d86c6a6b5d336c8f31df49 (diff)
Fix type info layout for wasm64p32 targets
-rw-r--r--src/llvm_backend_type.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/llvm_backend_type.cpp b/src/llvm_backend_type.cpp
index 20e4991e7..93e2874a5 100644
--- a/src/llvm_backend_type.cpp
+++ b/src/llvm_backend_type.cpp
@@ -205,7 +205,7 @@ gb_internal LLVMTypeRef *lb_setup_modified_types_for_type_info(lbModule *m, isiz
stypes[1] = lb_type(m, tibt->Struct.fields[1]->type);
stypes[2] = lb_type(m, tibt->Struct.fields[2]->type);
isize variant_index = 0;
- if (build_context.int_size == 8) {
+ if (build_context.ptr_size == 8) {
stypes[3] = lb_type(m, t_i32); // padding
stypes[4] = lb_type(m, tibt->Struct.fields[3]->type);
variant_index = 5;
@@ -385,7 +385,7 @@ gb_internal void lb_setup_type_info_data_giant_array(lbModule *m, i64 global_typ
small_const_values[2] = type_info_flags.value;
unsigned variant_index = 0;
- if (build_context.int_size == 8) {
+ if (build_context.ptr_size == 8) {
small_const_values[3] = LLVMConstNull(LLVMStructGetTypeAtIndex(stype, 3));
small_const_values[4] = id.value;
variant_index = 5;