From 79e86252208848020e0b13d77b8c6918e92b8328 Mon Sep 17 00:00:00 2001 From: "Michael J. Spencer" Date: Sat, 18 Dec 2010 22:23:15 +0000 Subject: [PATCH] Fix whitespace. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@122158 91177308-0d34-0410-b5e6-96231b3b80d8 --- lib/Linker/LinkModules.cpp | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/lib/Linker/LinkModules.cpp b/lib/Linker/LinkModules.cpp index c710d7ee869..f6c7d032524 100644 --- a/lib/Linker/LinkModules.cpp +++ b/lib/Linker/LinkModules.cpp @@ -449,7 +449,7 @@ static void LinkNamedMDNodes(Module *Dest, Module *Src, const NamedMDNode *SrcNMD = I; NamedMDNode *DestNMD = Dest->getOrInsertNamedMetadata(SrcNMD->getName()); // Add Src elements into Dest node. - for (unsigned i = 0, e = SrcNMD->getNumOperands(); i != e; ++i) + for (unsigned i = 0, e = SrcNMD->getNumOperands(); i != e; ++i) DestNMD->addOperand(cast(MapValue(SrcNMD->getOperand(i), ValueMap, true))); @@ -559,14 +559,14 @@ static bool LinkGlobals(Module *Dest, const Module *Src, // we are replacing may be a function (if a prototype, weak, etc) or a // global variable. GlobalVariable *NewDGV = - new GlobalVariable(*Dest, SGV->getType()->getElementType(), - SGV->isConstant(), NewLinkage, /*init*/0, + new GlobalVariable(*Dest, SGV->getType()->getElementType(), + SGV->isConstant(), NewLinkage, /*init*/0, DGV->getName(), 0, false, SGV->getType()->getAddressSpace()); // Propagate alignment, section, and visibility info. CopyGVAttributes(NewDGV, SGV); - DGV->replaceAllUsesWith(ConstantExpr::getBitCast(NewDGV, + DGV->replaceAllUsesWith(ConstantExpr::getBitCast(NewDGV, DGV->getType())); // DGV will conflict with NewDGV because they both had the same @@ -928,7 +928,7 @@ static bool LinkFunctionProtos(Module *Dest, const Module *Src, CopyGVAttributes(NewDF, SF); // Any uses of DF need to change to NewDF, with cast - DGV->replaceAllUsesWith(ConstantExpr::getBitCast(NewDF, + DGV->replaceAllUsesWith(ConstantExpr::getBitCast(NewDF, DGV->getType())); // DF will conflict with NewDF because they both had the same. We must @@ -1017,7 +1017,7 @@ static bool LinkFunctionBody(Function *Dest, Function *Src, Value *Old = MI->second; if (!isa(Old) && !isa(Old)) { Value *New = MapValue(Old, ValueMap, true); - if (New != Old) + if (New != Old) I->setMetadata(MI->first, cast(New)); } } @@ -1100,7 +1100,7 @@ static bool LinkAppendingVars(Module *M, "Appending variables with different section name need to be linked!"); unsigned NewSize = T1->getNumElements() + T2->getNumElements(); - ArrayType *NewType = ArrayType::get(T1->getElementType(), + ArrayType *NewType = ArrayType::get(T1->getElementType(), NewSize); G1->setName(""); // Clear G1's name in case of a conflict! @@ -1144,7 +1144,7 @@ static bool LinkAppendingVars(Module *M, // getelementptr instructions to not use the Cast! G1->replaceAllUsesWith(ConstantExpr::getBitCast(NG, G1->getType())); - G2->replaceAllUsesWith(ConstantExpr::getBitCast(NG, + G2->replaceAllUsesWith(ConstantExpr::getBitCast(NG, G2->getType())); // Remove the two globals from the module now...