diff gen/typinf.cpp @ 1452:638d16625da2

LDC 2 compiles again.
author Robert Clipsham <robert@octarineparrot.com>
date Sat, 30 May 2009 17:23:32 +0100
parents a0a4d4dac1a4
children a5526b7a5ae6
line wrap: on
line diff
--- a/gen/typinf.cpp	Thu May 28 00:07:21 2009 +0200
+++ b/gen/typinf.cpp	Sat May 30 17:23:32 2009 +0100
@@ -434,7 +434,11 @@
     else
     {
         const LLType* memty = DtoType(sd->memtype);
+#if DMDV2
+        LLConstant* C = llvm::ConstantInt::get(memty, sd->defaultval->toInteger(), !sd->memtype->isunsigned());
+#else
         LLConstant* C = llvm::ConstantInt::get(memty, sd->defaultval, !sd->memtype->isunsigned());
+#endif
         b.push_void_array(C, sd->memtype, sd);
     }