summaryrefslogtreecommitdiff
path: root/MLKLLVMCompiler.mm
diff options
context:
space:
mode:
authorMatthias Andreas Benkard <matthias@benkard.de>2008-08-11 19:29:51 +0200
committerMatthias Andreas Benkard <matthias@benkard.de>2008-08-11 19:29:51 +0200
commit1bf467cd776bbbcb79ca11da2a2d94cf58753ba5 (patch)
treea17045cd8e93e4482ca80634bd424103818fc5d8 /MLKLLVMCompiler.mm
parent7af4077884b2a9aadbed2fd8ff56266874252c35 (diff)
LLVM compiler: Support empty PROGN forms.
Diffstat (limited to 'MLKLLVMCompiler.mm')
-rw-r--r--MLKLLVMCompiler.mm3
1 files changed, 3 insertions, 0 deletions
diff --git a/MLKLLVMCompiler.mm b/MLKLLVMCompiler.mm
index 7490b32..249ac39 100644
--- a/MLKLLVMCompiler.mm
+++ b/MLKLLVMCompiler.mm
@@ -130,6 +130,9 @@ static FunctionPassManager *fpm;
MLKForm *form;
Value *value;
+ if ([_bodyForms count] == 0)
+ value = ConstantPointerNull::get (PointerType::get(Type::VoidTy, 0));
+
while ((form = [e nextObject]))
{
value = [form processForLLVM];