aboutsummaryrefslogtreecommitdiff
path: root/lib/AST/Type.cpp
diff options
context:
space:
mode:
authorDouglas Gregor <dgregor@apple.com>2010-06-22 23:13:52 +0000
committerDouglas Gregor <dgregor@apple.com>2010-06-22 23:13:52 +0000
commit4b1317264037732fff3653ac6f494b124c726e1b (patch)
treed056f1402a6656876bc09dcf5aa7fe75c58ad4c2 /lib/AST/Type.cpp
parent0c293ea13d452c1a47a05ada5a5ee9acc69c66cc (diff)
Teach Type::isRealType() that vector types are never real types. All
of the callers of isRealType() already assumed this, and one of them (increment/decrement) mistakenly permitted increments of vector types because of it. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@106596 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/AST/Type.cpp')
-rw-r--r--lib/AST/Type.cpp2
1 files changed, 0 insertions, 2 deletions
diff --git a/lib/AST/Type.cpp b/lib/AST/Type.cpp
index a8ead6d46b..af4b7eb3a6 100644
--- a/lib/AST/Type.cpp
+++ b/lib/AST/Type.cpp
@@ -585,8 +585,6 @@ bool Type::isRealType() const {
BT->getKind() <= BuiltinType::LongDouble;
if (const TagType *TT = dyn_cast<TagType>(CanonicalType))
return TT->getDecl()->isEnum() && TT->getDecl()->isDefinition();
- if (const VectorType *VT = dyn_cast<VectorType>(CanonicalType))
- return VT->getElementType()->isRealType();
return false;
}