summaryrefslogtreecommitdiffstats
path: root/llvm/lib
diff options
context:
space:
mode:
authorChris Lattner <sabre@nondot.org>2003-08-18 16:54:48 +0000
committerChris Lattner <sabre@nondot.org>2003-08-18 16:54:48 +0000
commitab69ecc6d5b26dd063a67bdae2e7e89bfe7be5bb (patch)
treeecfe8ec6d839e7b69511d1aee94083b4867ab988 /llvm/lib
parenta592cac43c3e68db92158307bcbc7d8a5133faf2 (diff)
downloadbcm5719-llvm-ab69ecc6d5b26dd063a67bdae2e7e89bfe7be5bb.tar.gz
bcm5719-llvm-ab69ecc6d5b26dd063a67bdae2e7e89bfe7be5bb.zip
Fix linking bug in xboard
llvm-svn: 7952
Diffstat (limited to 'llvm/lib')
-rw-r--r--llvm/lib/VMCore/Constants.cpp5
1 files changed, 4 insertions, 1 deletions
diff --git a/llvm/lib/VMCore/Constants.cpp b/llvm/lib/VMCore/Constants.cpp
index ab4bdb390b9..eb93da3c1d0 100644
--- a/llvm/lib/VMCore/Constants.cpp
+++ b/llvm/lib/VMCore/Constants.cpp
@@ -213,7 +213,10 @@ ConstantArray::ConstantArray(const ArrayType *T,
const std::vector<Constant*> &V) : Constant(T) {
Operands.reserve(V.size());
for (unsigned i = 0, e = V.size(); i != e; ++i) {
- assert(V[i]->getType() == T->getElementType());
+ assert(V[i]->getType() == T->getElementType() ||
+ (T->isAbstract() &&
+ V[i]->getType()->getPrimitiveID() ==
+ T->getElementType()->getPrimitiveID()));
Operands.push_back(Use(V[i], this));
}
}
OpenPOWER on IntegriCloud