diff options
Diffstat (limited to 'clang/tools/libclang/CXIndexDataConsumer.cpp')
| -rw-r--r-- | clang/tools/libclang/CXIndexDataConsumer.cpp | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/clang/tools/libclang/CXIndexDataConsumer.cpp b/clang/tools/libclang/CXIndexDataConsumer.cpp index 00ade2ee8f0..3dec36a5dae 100644 --- a/clang/tools/libclang/CXIndexDataConsumer.cpp +++ b/clang/tools/libclang/CXIndexDataConsumer.cpp @@ -222,9 +222,11 @@ bool CXIndexDataConsumer::handleDeclOccurence( } bool CXIndexDataConsumer::handleModuleOccurence(const ImportDecl *ImportD, + const Module *Mod, SymbolRoleSet Roles, SourceLocation Loc) { - IndexingDeclVisitor(*this, SourceLocation(), nullptr).Visit(ImportD); + if (Roles & (SymbolRoleSet)SymbolRole::Declaration) + IndexingDeclVisitor(*this, SourceLocation(), nullptr).Visit(ImportD); return !shouldAbort(); } |

