diff options
Diffstat (limited to 'tools/libclang/IndexingContext.cpp')
-rw-r--r-- | tools/libclang/IndexingContext.cpp | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/tools/libclang/IndexingContext.cpp b/tools/libclang/IndexingContext.cpp index b5da6461bc..f597797132 100644 --- a/tools/libclang/IndexingContext.cpp +++ b/tools/libclang/IndexingContext.cpp @@ -736,7 +736,12 @@ void IndexingContext::getEntityInfo(const NamedDecl *D, EntityInfo.kind = CXIdxEntity_CXXStaticVariable; break; case Decl::Field: - EntityInfo.kind = CXIdxEntity_Field; break; + EntityInfo.kind = CXIdxEntity_Field; + if (const CXXRecordDecl * + CXXRec = dyn_cast<CXXRecordDecl>(D->getDeclContext())) + if (!CXXRec->isPOD()) + EntityInfo.kind = CXIdxEntity_CXXInstanceVariable; + break; case Decl::EnumConstant: EntityInfo.kind = CXIdxEntity_EnumConstant; break; case Decl::ObjCInterface: |