diff options
| author | Alexis Hunt <alercah@gmail.com> | 2011-05-24 22:41:36 +0000 |
|---|---|---|
| committer | Alexis Hunt <alercah@gmail.com> | 2011-05-24 22:41:36 +0000 |
| commit | e852b100e26c818788708a2379d047e157ea316f (patch) | |
| tree | 4df08da63c06554866280991bc227909575cce98 /clang/tools/libclang/CIndex.cpp | |
| parent | 93e7b3a8bdbe1a9edb1c3d6524ed858377b35e62 (diff) | |
| download | bcm5719-llvm-e852b100e26c818788708a2379d047e157ea316f.tar.gz bcm5719-llvm-e852b100e26c818788708a2379d047e157ea316f.zip | |
Implement a new type node, UnaryTransformType, designed to represent a
type that turns one type into another. This is used as the basis to
implement __underlying_type properly - with TypeSourceInfo and proper
behavior in the face of templates.
llvm-svn: 132017
Diffstat (limited to 'clang/tools/libclang/CIndex.cpp')
| -rw-r--r-- | clang/tools/libclang/CIndex.cpp | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/clang/tools/libclang/CIndex.cpp b/clang/tools/libclang/CIndex.cpp index 00141184c70..7348491072f 100644 --- a/clang/tools/libclang/CIndex.cpp +++ b/clang/tools/libclang/CIndex.cpp @@ -350,6 +350,7 @@ public: bool VisitTypeOfExprTypeLoc(TypeOfExprTypeLoc TL); bool VisitPackExpansionTypeLoc(PackExpansionTypeLoc TL); bool VisitTypeOfTypeLoc(TypeOfTypeLoc TL); + bool VisitUnaryTransformTypeLoc(UnaryTransformTypeLoc TL); bool VisitDependentNameTypeLoc(DependentNameTypeLoc TL); bool VisitDependentTemplateSpecializationTypeLoc( DependentTemplateSpecializationTypeLoc TL); @@ -1553,6 +1554,13 @@ bool CursorVisitor::VisitTypeOfTypeLoc(TypeOfTypeLoc TL) { return false; } +bool CursorVisitor::VisitUnaryTransformTypeLoc(UnaryTransformTypeLoc TL) { + if (TypeSourceInfo *TSInfo = TL.getUnderlyingTInfo()) + return Visit(TSInfo->getTypeLoc()); + + return false; +} + bool CursorVisitor::VisitDependentNameTypeLoc(DependentNameTypeLoc TL) { if (VisitNestedNameSpecifierLoc(TL.getQualifierLoc())) return true; |

