diff options
| author | Laytan <laytanlaats@hotmail.com> | 2025-11-04 20:14:53 +0100 |
|---|---|---|
| committer | Laytan Laats <laytanlaats@hotmail.com> | 2025-11-04 21:37:29 +0100 |
| commit | c4d1cd6ee5b903f7ef8c2d9adbded1144b428b86 (patch) | |
| tree | 5e42a30bdcb9b4da09d9306f2cf6db234890737f /src/llvm_backend_utility.cpp | |
| parent | 9893a0eaea81e1411a04534fab8134716a4f59e5 (diff) | |
fixes for 32bit with regards to typeid
Diffstat (limited to 'src/llvm_backend_utility.cpp')
| -rw-r--r-- | src/llvm_backend_utility.cpp | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/llvm_backend_utility.cpp b/src/llvm_backend_utility.cpp index c7b4170e9..33ad2ee8d 100644 --- a/src/llvm_backend_utility.cpp +++ b/src/llvm_backend_utility.cpp @@ -1005,6 +1005,7 @@ gb_internal i32 lb_convert_struct_index(lbModule *m, Type *t, i32 index) { switch (index) { case 0: return 0; // data case 1: return 2; // id + default: GB_PANIC("index > 1"); } } else if (build_context.ptr_size != build_context.int_size) { switch (t->kind) { @@ -1203,6 +1204,7 @@ gb_internal lbValue lb_emit_struct_ep(lbProcedure *p, lbValue s, i32 index) { switch (index) { case 0: result_type = t_rawptr; break; case 1: result_type = t_typeid; break; + default: GB_PANIC("index > 1"); } } else if (is_type_dynamic_array(t)) { switch (index) { |