summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--clang/lib/Index/IndexDecl.cpp5
-rw-r--r--clang/test/Index/Core/index-source.m3
2 files changed, 5 insertions, 3 deletions
diff --git a/clang/lib/Index/IndexDecl.cpp b/clang/lib/Index/IndexDecl.cpp
index 0e893505516..9bf19270e8d 100644
--- a/clang/lib/Index/IndexDecl.cpp
+++ b/clang/lib/Index/IndexDecl.cpp
@@ -231,10 +231,11 @@ public:
}
bool VisitTypedefNameDecl(const TypedefNameDecl *D) {
- if (!D->isTransparentTag())
+ if (!D->isTransparentTag()) {
if (!IndexCtx.handleDecl(D))
return false;
- IndexCtx.indexTypeSourceInfo(D->getTypeSourceInfo(), D);
+ IndexCtx.indexTypeSourceInfo(D->getTypeSourceInfo(), D);
+ }
return true;
}
diff --git a/clang/test/Index/Core/index-source.m b/clang/test/Index/Core/index-source.m
index f48891417f5..a2eef89deea 100644
--- a/clang/test/Index/Core/index-source.m
+++ b/clang/test/Index/Core/index-source.m
@@ -353,7 +353,8 @@ typedef MyGenCls<Base *><MyEnumerating> MyEnumerator;
typedef NS_ENUM(AnotherEnum, int) {
// CHECK-NOT: [[@LINE-1]]:17 | type-alias/C | AnotherEnum |
-// CHECK: [[@LINE-2]]:17 | enum/C | AnotherEnum | [[AnotherEnum_USR:.*]] | {{.*}} | Ref,RelCont | rel: 1
+// CHECK-NOT: [[@LINE-2]]:17 | {{.*}} | Ref
+// CHECK: [[@LINE-3]]:17 | enum/C | AnotherEnum | [[AnotherEnum_USR:.*]] | {{.*}} | Def | rel: 0
AnotherEnumFirst = 0,
AnotherEnumSecond = 1,
AnotherEnumThird = 2,
OpenPOWER on IntegriCloud