[PATCH] D42895: [libclang] Add `CXSymbolRole role` to CXIdxEntityRefInfo

2018-02-12 Thread Fangrui Song via Phabricator via cfe-commits
MaskRay added a comment. Thx! Repository: rL LLVM https://reviews.llvm.org/D42895 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D42895: [libclang] Add `CXSymbolRole role` to CXIdxEntityRefInfo

2018-02-12 Thread Fangrui Song via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rC324914: [libclang] Add `CXSymbolRole role` to CXIdxEntityRefInfo (authored by MaskRay, committed by ). Changed prior to commit: https://reviews.llvm.org/D42895?vs=133632=133890#toc Repository: rL

[PATCH] D42895: [libclang] Add `CXSymbolRole role` to CXIdxEntityRefInfo

2018-02-12 Thread Fangrui Song via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL324914: [libclang] Add `CXSymbolRole role` to CXIdxEntityRefInfo (authored by MaskRay, committed by ). Herald added a subscriber: llvm-commits. Changed prior to commit:

[PATCH] D42895: [libclang] Add `CXSymbolRole role` to CXIdxEntityRefInfo

2018-02-12 Thread Ilya Biryukov via Phabricator via cfe-commits
ilya-biryukov accepted this revision. ilya-biryukov added a comment. This revision is now accepted and ready to land. LGTM. > Is it possible to see this landed before clang+llvm 6 is released? I don't know in detail how releases work, but I believe the release branch has already been created

[PATCH] D42895: [libclang] Add `CXSymbolRole role` to CXIdxEntityRefInfo

2018-02-10 Thread Fangrui Song via Phabricator via cfe-commits
MaskRay added a comment. Ping. Now this is a pure API extension to current implicit/direct roles. Is it possible to see this landed before clang+llvm 6 is released? Repository: rC Clang https://reviews.llvm.org/D42895 ___ cfe-commits mailing

[PATCH] D42895: [libclang] Add `CXSymbolRole role` to CXIdxEntityRefInfo

2018-02-09 Thread Fangrui Song via Phabricator via cfe-commits
MaskRay updated this revision to Diff 133632. MaskRay added a comment. Bring back refkind: Repository: rC Clang https://reviews.llvm.org/D42895 Files: include/clang-c/Index.h include/clang/Index/IndexSymbol.h test/Index/index-refs.cpp test/Index/index-subscripting-literals.m

[PATCH] D42895: [libclang] Add `CXSymbolRole role` to CXIdxEntityRefInfo

2018-02-09 Thread Ilya Biryukov via Phabricator via cfe-commits
ilya-biryukov added inline comments. Comment at: include/clang-c/Index.h:6159 + */ + CXSymbolRole role; } CXIdxEntityRefInfo; MaskRay wrote: > ilya-biryukov wrote: > > MaskRay wrote: > > > ilya-biryukov wrote: > > > > Why do we need to store both

[PATCH] D42895: [libclang] Add `CXSymbolRole role` to CXIdxEntityRefInfo

2018-02-08 Thread Fangrui Song via Phabricator via cfe-commits
MaskRay marked 4 inline comments as done. MaskRay added inline comments. Comment at: include/clang-c/Index.h:6159 + */ + CXSymbolRole role; } CXIdxEntityRefInfo; ilya-biryukov wrote: > MaskRay wrote: > > ilya-biryukov wrote: > > > Why do we need to store

[PATCH] D42895: [libclang] Add `CXSymbolRole role` to CXIdxEntityRefInfo

2018-02-08 Thread Fangrui Song via Phabricator via cfe-commits
MaskRay updated this revision to Diff 133441. MaskRay added a comment. Don't deprecate CXIdxEntityRefInfo Repository: rC Clang https://reviews.llvm.org/D42895 Files: include/clang-c/Index.h include/clang/Index/IndexSymbol.h test/Index/index-decls.m test/Index/index-refs.cpp

[PATCH] D42895: [libclang] Add `CXSymbolRole role` to CXIdxEntityRefInfo

2018-02-08 Thread Ilya Biryukov via Phabricator via cfe-commits
ilya-biryukov added inline comments. Comment at: include/clang-c/Index.h:6159 + */ + CXSymbolRole role; } CXIdxEntityRefInfo; MaskRay wrote: > ilya-biryukov wrote: > > Why do we need to store both `CXIdxEntityRefKind` and `CXSymbolRole`? Can > > we store

[PATCH] D42895: [libclang] Add `CXSymbolRole role` to CXIdxEntityRefInfo

2018-02-07 Thread Fangrui Song via Phabricator via cfe-commits
MaskRay marked 2 inline comments as done. MaskRay added inline comments. Comment at: include/clang-c/Index.h:6159 + */ + CXSymbolRole role; } CXIdxEntityRefInfo; ilya-biryukov wrote: > Why do we need to store both `CXIdxEntityRefKind` and `CXSymbolRole`? Can

[PATCH] D42895: [libclang] Add `CXSymbolRole role` to CXIdxEntityRefInfo

2018-02-07 Thread Ilya Biryukov via Phabricator via cfe-commits
ilya-biryukov added inline comments. Comment at: include/clang-c/Index.h:6159 + */ + CXSymbolRole role; } CXIdxEntityRefInfo; Why do we need to store both `CXIdxEntityRefKind` and `CXSymbolRole`? Can we store just `CXSymbolRole`? Is this for compatibility

[PATCH] D42895: [libclang] Add `CXSymbolRole role` to CXIdxEntityRefInfo

2018-02-07 Thread Ivan Donchevskii via Phabricator via cfe-commits
yvvan added reviewers: ilya-biryukov, bkramer, arphaman. yvvan added a comment. Looks ok-ish, I haven't built it though. Also I don't have much exp with indexing part of libclang. Adding more reviewers. Repository: rC Clang https://reviews.llvm.org/D42895

[PATCH] D42895: [libclang] Add `CXSymbolRole role` to CXIdxEntityRefInfo

2018-02-06 Thread Fangrui Song via Phabricator via cfe-commits
MaskRay updated this revision to Diff 133051. MaskRay added a comment. . Repository: rC Clang https://reviews.llvm.org/D42895 Files: include/clang-c/Index.h test/Index/index-decls.m test/Index/index-refs.cpp test/Index/index-subscripting-literals.m

[PATCH] D42895: [libclang] Add `CXSymbolRole role` to CXIdxEntityRefInfo

2018-02-06 Thread Fangrui Song via Phabricator via cfe-commits
MaskRay updated this revision to Diff 133050. MaskRay added a comment. Simplify Repository: rC Clang https://reviews.llvm.org/D42895 Files: include/clang-c/Index.h test/Index/index-decls.m test/Index/index-refs.cpp test/Index/index-subscripting-literals.m

[PATCH] D42895: [libclang] Add `CXSymbolRole role` to CXIdxEntityRefInfo

2018-02-06 Thread Fangrui Song via Phabricator via cfe-commits
MaskRay added a comment. In https://reviews.llvm.org/D42895#998617, @yvvan wrote: > I feel quite ok about this patch. > > Can you please add unit-tests? Added // CHECK: [indexEntityReference]: kind: field | name: y | {{.*}} | loc: 70:5 | {{.*}} | role: ref write // CHECK:

[PATCH] D42895: [libclang] Add `CXSymbolRole role` to CXIdxEntityRefInfo

2018-02-06 Thread Fangrui Song via Phabricator via cfe-commits
MaskRay updated this revision to Diff 133038. MaskRay added a comment. Update c-index-test.c and clang/test/Index tests Repository: rC Clang https://reviews.llvm.org/D42895 Files: include/clang-c/Index.h test/Index/index-decls.m test/Index/index-refs.cpp

[PATCH] D42895: [libclang] Add `CXSymbolRole role` to CXIdxEntityRefInfo

2018-02-05 Thread Ivan Donchevskii via Phabricator via cfe-commits
yvvan added a comment. I feel quite ok about this patch. Can you please add unit-tests? Repository: rC Clang https://reviews.llvm.org/D42895 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[PATCH] D42895: [libclang] Add `CXSymbolRole role` to CXIdxEntityRefInfo

2018-02-04 Thread Fangrui Song via Phabricator via cfe-commits
MaskRay created this revision. Herald added a subscriber: cfe-commits. CXIdxEntityRefInfo contains the member `CXIdxEntityRefKind kind;` to differentiate implicit and direct calls. However, there are more roles defined in SymbolRole. Among them, `Read/Write` are probably the most useful ones as