diff options
| author | Andrew Kelley <superjoe30@gmail.com> | 2016-12-22 00:46:17 -0500 |
|---|---|---|
| committer | Andrew Kelley <superjoe30@gmail.com> | 2016-12-22 00:46:17 -0500 |
| commit | 46033a2128b09ed15f38f6ed2602bf80989a770f (patch) | |
| tree | 6a5e2df1c15ac9fd6f48181adb12e150d98d63be /src/codegen.cpp | |
| parent | 23bebdbcd51ac426f829713ce278b86ccaeb97f4 (diff) | |
| download | zig-46033a2128b09ed15f38f6ed2602bf80989a770f.tar.gz zig-46033a2128b09ed15f38f6ed2602bf80989a770f.zip | |
pass void parameters test
Diffstat (limited to 'src/codegen.cpp')
| -rw-r--r-- | src/codegen.cpp | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/src/codegen.cpp b/src/codegen.cpp index 49a6f4739b..b28b370f9a 100644 --- a/src/codegen.cpp +++ b/src/codegen.cpp @@ -1650,6 +1650,9 @@ static LLVMValueRef ir_render_switch_br(CodeGen *g, IrExecutable *executable, Ir } static LLVMValueRef ir_render_phi(CodeGen *g, IrExecutable *executable, IrInstructionPhi *instruction) { + if (!type_has_bits(instruction->base.type_entry)) + return nullptr; + LLVMTypeRef phi_type; if (handle_is_ptr(instruction->base.type_entry)) { phi_type = LLVMPointerType(instruction->base.type_entry->type_ref, 0); |
