diff options
author | Andrew Lenharth <andrewl@lenharth.org> | 2006-12-08 18:06:16 +0000 |
---|---|---|
committer | Andrew Lenharth <andrewl@lenharth.org> | 2006-12-08 18:06:16 +0000 |
commit | 38ecbf18eb9c8ca7ae08dfed4dc6fb4e3e5deb1e (patch) | |
tree | 25f918d862f8baff414df9382c194b5b5e072de1 /lib/VMCore/Constants.cpp | |
parent | 8894255fc01cd8dcdccc700fdd69186d02131ffe (diff) |
Packed Structures
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@32361 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/VMCore/Constants.cpp')
-rw-r--r-- | lib/VMCore/Constants.cpp | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/lib/VMCore/Constants.cpp b/lib/VMCore/Constants.cpp index 5f1aaea909..b59341d927 100644 --- a/lib/VMCore/Constants.cpp +++ b/lib/VMCore/Constants.cpp @@ -1150,12 +1150,12 @@ Constant *ConstantStruct::get(const StructType *Ty, return ConstantAggregateZero::get(Ty); } -Constant *ConstantStruct::get(const std::vector<Constant*> &V) { +Constant *ConstantStruct::get(const std::vector<Constant*> &V, bool packed) { std::vector<const Type*> StructEls; StructEls.reserve(V.size()); for (unsigned i = 0, e = V.size(); i != e; ++i) StructEls.push_back(V[i]->getType()); - return get(StructType::get(StructEls), V); + return get(StructType::get(StructEls, packed), V); } // destroyConstant - Remove the constant from the constant table... @@ -2183,4 +2183,3 @@ std::string Constant::getStringValue(bool Chop, unsigned Offset) { } return ""; } - |