[clangd] Remove bad assert: nothing relies on it, and the reasons it was true no longer hold.

llvm-svn: 367672
This commit is contained in:
Sam McCall 2019-08-02 10:39:46 +00:00
parent 207e3af501
commit ad66e95b0d
1 changed files with 2 additions and 3 deletions

View File

@ -208,10 +208,8 @@ public:
private:
void finish() override {
if (auto DefinedMacro = locateMacroAt(SearchedLocation, PP)) {
if (auto DefinedMacro = locateMacroAt(SearchedLocation, PP))
MacroInfos.push_back(*DefinedMacro);
assert(Decls.empty());
}
}
};
@ -438,6 +436,7 @@ std::vector<DocumentHighlight> findDocumentHighlights(ParsedAST &AST,
const SourceManager &SM = AST.getSourceManager();
auto Symbols = getSymbolAtPosition(
AST, getBeginningOfIdentifier(AST, Pos, SM.getMainFileID()));
// FIXME: show references to macro within file?
auto References = findRefs(Symbols.Decls, AST);
std::vector<DocumentHighlight> Result;