aboutsummaryrefslogtreecommitdiffstats
path: root/lib/Linker
diff options
context:
space:
mode:
authorOwen Anderson <resistor@mac.com>2009-07-31 20:28:14 +0000
committerOwen Anderson <resistor@mac.com>2009-07-31 20:28:14 +0000
commita7235ea7245028a0723e8ab7fd011386b3900777 (patch)
tree4d702ea3baaaeaeaeb5cf194e266a0911882c613 /lib/Linker
parent2a29899d74476e2a14069af7231ab76d8322a157 (diff)
downloadexternal_llvm-a7235ea7245028a0723e8ab7fd011386b3900777.zip
external_llvm-a7235ea7245028a0723e8ab7fd011386b3900777.tar.gz
external_llvm-a7235ea7245028a0723e8ab7fd011386b3900777.tar.bz2
Move a few more APIs back to 2.5 forms. The only remaining ones left to change back are
metadata related, which I'm waiting on to avoid conflicting with Devang. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@77721 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Linker')
-rw-r--r--lib/Linker/LinkModules.cpp6
1 files changed, 2 insertions, 4 deletions
diff --git a/lib/Linker/LinkModules.cpp b/lib/Linker/LinkModules.cpp
index 4d9b061..ccab2de 100644
--- a/lib/Linker/LinkModules.cpp
+++ b/lib/Linker/LinkModules.cpp
@@ -1108,8 +1108,6 @@ static bool LinkAppendingVars(Module *M,
std::string *ErrorMsg) {
if (AppendingVars.empty()) return false; // Nothing to do.
- LLVMContext &Context = M->getContext();
-
// Loop over the multimap of appending vars, processing any variables with the
// same name, forming a new appending global variable with both of the
// initializers merged together, then rewrite references to the old variables
@@ -1169,7 +1167,7 @@ static bool LinkAppendingVars(Module *M,
Inits.push_back(I->getOperand(i));
} else {
assert(isa<ConstantAggregateZero>(G1->getInitializer()));
- Constant *CV = Context.getNullValue(T1->getElementType());
+ Constant *CV = Constant::getNullValue(T1->getElementType());
for (unsigned i = 0, e = T1->getNumElements(); i != e; ++i)
Inits.push_back(CV);
}
@@ -1178,7 +1176,7 @@ static bool LinkAppendingVars(Module *M,
Inits.push_back(I->getOperand(i));
} else {
assert(isa<ConstantAggregateZero>(G2->getInitializer()));
- Constant *CV = Context.getNullValue(T2->getElementType());
+ Constant *CV = Constant::getNullValue(T2->getElementType());
for (unsigned i = 0, e = T2->getNumElements(); i != e; ++i)
Inits.push_back(CV);
}