From: Reid Spencer Date: Fri, 26 Jan 2007 07:51:36 +0000 (+0000) Subject: IntegerType is a sized DerivedType too. X-Git-Url: http://demsky.eecs.uci.edu/git/?a=commitdiff_plain;h=43276ee2803262aaa85bea23b1a100ded33b0ae9;p=oota-llvm.git IntegerType is a sized DerivedType too. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@33521 91177308-0d34-0410-b5e6-96231b3b80d8 --- diff --git a/lib/VMCore/Type.cpp b/lib/VMCore/Type.cpp index d1cdc5fe2ef..ec7aee80311 100644 --- a/lib/VMCore/Type.cpp +++ b/lib/VMCore/Type.cpp @@ -139,6 +139,9 @@ unsigned Type::getPrimitiveSizeInBits() const { /// iff all of the members of the type are sized as well. Since asking for /// their size is relatively uncommon, move this operation out of line. bool Type::isSizedDerivedType() const { + if (isa(this)) + return true; + if (const ArrayType *ATy = dyn_cast(this)) return ATy->getElementType()->isSized();