[SourceKit] Allow module references to be indexed (#19243)

Module references get indexed as a 'module' symbol; they get USRs similar to how clang would assign a USR for a module reference.

JIRA: https://bugs.swift.org/browse/SR-8677
This commit is contained in:
Bruno Rocha
2018-09-28 16:21:38 -03:00
committed by Argyrios Kyrtzidis
parent bb36ddfc17
commit bf84b297f8
19 changed files with 189 additions and 21 deletions

View File

@@ -583,6 +583,9 @@ UIdent SwiftLangSupport::getUIDForSymbol(SymbolInfo sym, bool isRef) {
llvm_unreachable("missing extension sub kind");
}
case SymbolKind::Module:
return KindRefModule;
default:
// TODO: reconsider whether having a default case is a good idea.
return UIdent();