aboutsummaryrefslogtreecommitdiff
path: root/src/analyze.cpp
diff options
context:
space:
mode:
authorAndrew Kelley <superjoe30@gmail.com>2017-01-15 23:27:14 -0500
committerAndrew Kelley <superjoe30@gmail.com>2017-01-15 23:27:14 -0500
commitd0b59f20ab3285b11c5e8a8201991dc5fc90b3c9 (patch)
treef69b457498f58bf51b9d32df836ed4194c51e638 /src/analyze.cpp
parent0b6cf0aa637b5cd7551aca295832f06d56315921 (diff)
downloadzig-d0b59f20ab3285b11c5e8a8201991dc5fc90b3c9.tar.gz
zig-d0b59f20ab3285b11c5e8a8201991dc5fc90b3c9.zip
fix llvm assertion failure for zero bits structs
Diffstat (limited to 'src/analyze.cpp')
-rw-r--r--src/analyze.cpp1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/analyze.cpp b/src/analyze.cpp
index b8fa326ca0..de73ed70f7 100644
--- a/src/analyze.cpp
+++ b/src/analyze.cpp
@@ -1362,6 +1362,7 @@ static void resolve_struct_type(CodeGen *g, TypeTableEntry *struct_type) {
if (struct_type->zero_bits) {
struct_type->type_ref = LLVMVoidType();
+ ZigLLVMReplaceTemporary(g->dbuilder, struct_type->di_type, g->builtin_types.entry_void->di_type);
struct_type->di_type = g->builtin_types.entry_void->di_type;
return;
}