From 549311fac98ce447e8ab18d365841dc4f0671abf Mon Sep 17 00:00:00 2001 From: gingerBill Date: Mon, 15 Jul 2024 12:21:42 +0100 Subject: Fix global variables being "missing" with `-use-separate-modules` --- src/llvm_backend_debug.cpp | 1 + 1 file changed, 1 insertion(+) (limited to 'src/llvm_backend_debug.cpp') diff --git a/src/llvm_backend_debug.cpp b/src/llvm_backend_debug.cpp index f1ace5f06..c896f889d 100644 --- a/src/llvm_backend_debug.cpp +++ b/src/llvm_backend_debug.cpp @@ -1187,6 +1187,7 @@ gb_internal void add_debug_info_for_global_constant_from_entity(lbGenerator *gen if (USE_SEPARATE_MODULES) { m = lb_module_of_entity(gen, e); } + GB_ASSERT(m != nullptr); if (is_type_integer(e->type)) { ExactValue const &value = e->Constant.value; -- cgit v1.2.3