Lines 118-128
bool IndexDataConsumer::isAlreadyParsed(clang::FileID fileId, SourcesManager &so
Link Here
|
118 |
return sourcesManager.alreadyParsed(filePathId(fileEntry), fileEntry->getModificationTime()); |
118 |
return sourcesManager.alreadyParsed(filePathId(fileEntry), fileEntry->getModificationTime()); |
119 |
} |
119 |
} |
120 |
|
120 |
|
121 |
bool IndexDataConsumer::handleDeclOccurence(const clang::Decl *declaration, |
121 |
#if LLVM_VERSION_MAJOR >= 10 |
122 |
clang::index::SymbolRoleSet symbolRoles, |
122 |
bool IndexDataConsumer::handleDeclOccurrence( |
123 |
llvm::ArrayRef<clang::index::SymbolRelation> /*symbolRelations*/, |
123 |
#else |
124 |
clang::SourceLocation sourceLocation, |
124 |
bool IndexDataConsumer::handleDeclOccurence( |
125 |
IndexDataConsumer::ASTNodeInfo /*astNodeInfo*/) |
125 |
#endif |
|
|
126 |
const clang::Decl *declaration, |
127 |
clang::index::SymbolRoleSet symbolRoles, |
128 |
llvm::ArrayRef<clang::index::SymbolRelation> /*symbolRelations*/, |
129 |
clang::SourceLocation sourceLocation, |
130 |
IndexDataConsumer::ASTNodeInfo /*astNodeInfo*/) |
126 |
{ |
131 |
{ |
127 |
const auto *namedDeclaration = clang::dyn_cast<clang::NamedDecl>(declaration); |
132 |
const auto *namedDeclaration = clang::dyn_cast<clang::NamedDecl>(declaration); |
128 |
if (namedDeclaration) { |
133 |
if (namedDeclaration) { |
Lines 175-184
SourceLocationKind macroSymbolType(clang::index::SymbolRoleSet roles)
Link Here
|
175 |
|
180 |
|
176 |
} // namespace |
181 |
} // namespace |
177 |
|
182 |
|
178 |
bool IndexDataConsumer::handleMacroOccurence(const clang::IdentifierInfo *identifierInfo, |
183 |
#if LLVM_VERSION_MAJOR >= 10 |
179 |
const clang::MacroInfo *macroInfo, |
184 |
bool IndexDataConsumer::handleMacroOccurrence( |
180 |
clang::index::SymbolRoleSet roles, |
185 |
#else |
181 |
clang::SourceLocation sourceLocation) |
186 |
bool IndexDataConsumer::handleMacroOccurence( |
|
|
187 |
#endif |
188 |
const clang::IdentifierInfo *identifierInfo, |
189 |
const clang::MacroInfo *macroInfo, |
190 |
clang::index::SymbolRoleSet roles, |
191 |
clang::SourceLocation sourceLocation) |
182 |
{ |
192 |
{ |
183 |
if (macroInfo && sourceLocation.isFileID() |
193 |
if (macroInfo && sourceLocation.isFileID() |
184 |
&& !isAlreadyParsed(m_sourceManager->getFileID(sourceLocation), m_macroSourcesManager) |
194 |
&& !isAlreadyParsed(m_sourceManager->getFileID(sourceLocation), m_macroSourcesManager) |