diff options
Diffstat (limited to 'lib/AST/Type.cpp')
-rw-r--r-- | lib/AST/Type.cpp | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/lib/AST/Type.cpp b/lib/AST/Type.cpp index 40b376bbd9..c06b1d9914 100644 --- a/lib/AST/Type.cpp +++ b/lib/AST/Type.cpp @@ -745,6 +745,12 @@ bool RecordType::classof(const Type *T) { return false; } +bool EnumType::classof(const Type *T) { + if (const TagType *TT = dyn_cast<TagType>(T)) + return isa<EnumDecl>(TT->getDecl()); + return false; +} + //===----------------------------------------------------------------------===// // Type Printing |