diff options
author | Chris Lattner <sabre@nondot.org> | 2012-01-25 01:32:59 +0000 |
---|---|---|
committer | Chris Lattner <sabre@nondot.org> | 2012-01-25 01:32:59 +0000 |
commit | af7b4fb9bec3858f0374d713dcbf3398a23c6fbe (patch) | |
tree | 5320eb10bc18e29dc860f77c25de62ed2475f975 /lib/VMCore/Type.cpp | |
parent | 0f193b8a6846dab25323788638e760ae03b7cd87 (diff) | |
download | llvm-af7b4fb9bec3858f0374d713dcbf3398a23c6fbe.tar.gz llvm-af7b4fb9bec3858f0374d713dcbf3398a23c6fbe.tar.bz2 llvm-af7b4fb9bec3858f0374d713dcbf3398a23c6fbe.tar.xz |
Remove the Type::getNumElements() method, which is only called in 4 places,
did something extremely surprising, and shadowed actually useful
implementations that had completely different behavior.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@148898 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/VMCore/Type.cpp')
-rw-r--r-- | lib/VMCore/Type.cpp | 8 |
1 files changed, 0 insertions, 8 deletions
diff --git a/lib/VMCore/Type.cpp b/lib/VMCore/Type.cpp index fe07e9e12e..7edd9e63f5 100644 --- a/lib/VMCore/Type.cpp +++ b/lib/VMCore/Type.cpp @@ -47,14 +47,6 @@ Type *Type::getScalarType() { return this; } -/// getNumElements - If this is a vector type, return the number of elements, -/// otherwise return zero. -unsigned Type::getNumElements() { - if (VectorType *VTy = dyn_cast<VectorType>(this)) - return VTy->getNumElements(); - return 0; -} - /// isIntegerTy - Return true if this is an IntegerType of the specified width. bool Type::isIntegerTy(unsigned Bitwidth) const { return isIntegerTy() && cast<IntegerType>(this)->getBitWidth() == Bitwidth; |