[vmkit-commits] [vmkit] r61693 - /vmkit/trunk/lib/JnJVM/VMCore/JnjvmModule.cpp

Nicolas Geoffray nicolas.geoffray at lip6.fr
Mon Jan 5 06:19:57 PST 2009


Author: geoffray
Date: Mon Jan  5 08:19:56 2009
New Revision: 61693

URL: http://llvm.org/viewvc/llvm-project?rev=61693&view=rev
Log:
Add an initializer to static instances.


Modified:
    vmkit/trunk/lib/JnJVM/VMCore/JnjvmModule.cpp

Modified: vmkit/trunk/lib/JnJVM/VMCore/JnjvmModule.cpp
URL: http://llvm.org/viewvc/llvm-project/vmkit/trunk/lib/JnJVM/VMCore/JnjvmModule.cpp?rev=61693&r1=61692&r2=61693&view=diff

==============================================================================
--- vmkit/trunk/lib/JnJVM/VMCore/JnjvmModule.cpp (original)
+++ vmkit/trunk/lib/JnJVM/VMCore/JnjvmModule.cpp Mon Jan  5 08:19:56 2009
@@ -291,9 +291,10 @@
     if (I == End) {
       LLVMClassInfo* LCI = getClassInfo(classDef);
       const Type* Ty = LCI->getStaticType();
-      varGV = new GlobalVariable(Ty->getContainedType(0), false,
+      Ty = Ty->getContainedType(0);
+      varGV = new GlobalVariable(Ty, false,
                                  GlobalValue::ExternalLinkage,
-                                 0, "", this);
+                                 Constant::getNullValue(Ty), "", this);
 
       Constant* res = ConstantExpr::getCast(Instruction::BitCast, varGV,
                                             ptrType);





More information about the vmkit-commits mailing list