[llvm-commits] CVS: llvm/lib/Linker/LinkModules.cpp
Chris Lattner
lattner at cs.uiuc.edu
Tue Dec 6 09:31:09 PST 2005
Changes in directory llvm/lib/Linker:
LinkModules.cpp updated: 1.107 -> 1.108
---
Log message:
Fix test/Regression/Linker/2005-12-06-AppendingZeroLengthArrays.ll and
PR662: http://llvm.cs.uiuc.edu/PR662 . Thanks to Markus for providing me with a ton of files to
reproduce the problem!
---
Diffs of the changes: (+2 -0)
LinkModules.cpp | 2 ++
1 files changed, 2 insertions(+)
Index: llvm/lib/Linker/LinkModules.cpp
diff -u llvm/lib/Linker/LinkModules.cpp:1.107 llvm/lib/Linker/LinkModules.cpp:1.108
--- llvm/lib/Linker/LinkModules.cpp:1.107 Thu Jul 7 18:21:43 2005
+++ llvm/lib/Linker/LinkModules.cpp Tue Dec 6 11:30:58 2005
@@ -748,6 +748,8 @@
unsigned NewSize = T1->getNumElements() + T2->getNumElements();
ArrayType *NewType = ArrayType::get(T1->getElementType(), NewSize);
+ G1->setName(""); // Clear G1's name in case of a conflict!
+
// Create the new global variable...
GlobalVariable *NG =
new GlobalVariable(NewType, G1->isConstant(), G1->getLinkage(),
More information about the llvm-commits
mailing list