diff ir/irstruct.cpp @ 1569:755abafbf25d

Push the context through StructType::get. Requires LLVM >= 78258. Also remove old #if's.
author Benjamin Kramer <benny.kra@gmail.com>
date Thu, 06 Aug 2009 01:47:39 +0200
parents 1d5c3354b3c2
children 8d086d552909
line wrap: on
line diff
--- a/ir/irstruct.cpp	Thu Aug 06 17:04:36 2009 +0200
+++ b/ir/irstruct.cpp	Thu Aug 06 01:47:39 2009 +0200
@@ -195,7 +195,7 @@
     }
 
     // build constant struct
-    llvm::Constant* definit = LLConstantStruct::get(constants, packed);
+    llvm::Constant* definit = LLConstantStruct::get(gIR->context(), constants, packed);
 #if 0
     IF_LOG Logger::cout() << "final default initializer: " << *definit << std::endl;
 #endif
@@ -384,7 +384,7 @@
 
     // build constant
     assert(!constants.empty());
-    llvm::Constant* c = LLConstantStruct::get(&constants[0], constants.size(), packed);
+    llvm::Constant* c = LLConstantStruct::get(gIR->context(), &constants[0], constants.size(), packed);
     IF_LOG Logger::cout() << "final struct initializer: " << *c << std::endl;
     return c;
 }