Skip to content

Commit

Permalink
Merge pull request #3360 from laytan/debug-info-fixes
Browse files Browse the repository at this point in the history
fix wrong type in map debug info
  • Loading branch information
Kelimion authored Apr 1, 2024
2 parents 6b7e9f0 + 4fc96e1 commit f9f6fbf
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/llvm_backend_debug.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -925,7 +925,7 @@ gb_internal LLVMMetadataRef lb_debug_type(lbModule *m, Type *type) {

String name = type->Named.name;
if (type->Named.type_name && type->Named.type_name->pkg && type->Named.type_name->pkg->name.len != 0) {
name = concatenate3_strings(permanent_allocator(), type->Named.type_name->pkg->name, str_lit("."), type->Named.name);
name = concatenate3_strings(temporary_allocator(), type->Named.type_name->pkg->name, str_lit("."), type->Named.name);
}

Type *bt = base_type(type->Named.base);
Expand All @@ -945,7 +945,7 @@ gb_internal LLVMMetadataRef lb_debug_type(lbModule *m, Type *type) {
}

case Type_Map: {
bt = base_type(type->Map.debug_metadata_type);
bt = base_type(bt->Map.debug_metadata_type);
GB_ASSERT(bt->kind == Type_Struct);
return lb_debug_struct(m, type, bt, name, scope, file, line);
}
Expand Down

0 comments on commit f9f6fbf

Please sign in to comment.