summaryrefslogtreecommitdiffstats
path: root/clang/lib/Index/IndexSymbol.cpp
diff options
context:
space:
mode:
authorArgyrios Kyrtzidis <akyrtzi@gmail.com>2016-10-25 21:11:22 +0000
committerArgyrios Kyrtzidis <akyrtzi@gmail.com>2016-10-25 21:11:22 +0000
commit806faaf42ba49fffaa9217c368d53bddd7e4fcf1 (patch)
treeddae84699bde6b4836e831e90e572b9d4aa7d0bc /clang/lib/Index/IndexSymbol.cpp
parent83fb4019f7ebd51cb0ede98e593a4e072bbabd57 (diff)
downloadbcm5719-llvm-806faaf42ba49fffaa9217c368d53bddd7e4fcf1.tar.gz
bcm5719-llvm-806faaf42ba49fffaa9217c368d53bddd7e4fcf1.zip
[index] Fixes for locations and relations in Objective C categories and getters/setters
- Add entries for protocols on categories - Add relation between categories and class they extend - Add relation between getters/setters and their corresponding property - Use category name location as the location of category decls/defs if it has one llvm-svn: 285120
Diffstat (limited to 'clang/lib/Index/IndexSymbol.cpp')
-rw-r--r--clang/lib/Index/IndexSymbol.cpp4
1 files changed, 4 insertions, 0 deletions
diff --git a/clang/lib/Index/IndexSymbol.cpp b/clang/lib/Index/IndexSymbol.cpp
index 13a84523007..65f5241037c 100644
--- a/clang/lib/Index/IndexSymbol.cpp
+++ b/clang/lib/Index/IndexSymbol.cpp
@@ -262,6 +262,8 @@ void index::applyForEachSymbolRole(SymbolRoleSet Roles,
APPLY_FOR_ROLE(RelationOverrideOf);
APPLY_FOR_ROLE(RelationReceivedBy);
APPLY_FOR_ROLE(RelationCalledBy);
+ APPLY_FOR_ROLE(RelationExtendedBy);
+ APPLY_FOR_ROLE(RelationAccessorOf);
#undef APPLY_FOR_ROLE
}
@@ -288,6 +290,8 @@ void index::printSymbolRoles(SymbolRoleSet Roles, raw_ostream &OS) {
case SymbolRole::RelationOverrideOf: OS << "RelOver"; break;
case SymbolRole::RelationReceivedBy: OS << "RelRec"; break;
case SymbolRole::RelationCalledBy: OS << "RelCall"; break;
+ case SymbolRole::RelationExtendedBy: OS << "RelExt"; break;
+ case SymbolRole::RelationAccessorOf: OS << "RelAcc"; break;
}
});
}
OpenPOWER on IntegriCloud