ilya-biryukov added a comment.

In D58341#1401295 <https://reviews.llvm.org/D58341#1401295>, @hokein wrote:
> std::strcmp is a fair case here. Sema seems not returning using-decls as part 
> of code completion results, it this an intended behavior?


Yeah, I think it is. There's an explicit code path that takes the target decls 
of a using. Arguably, that's good if you to show signatures of the methods.

> Is it possible for us to extend Sema to support it?

We could, but then we'd loose the signatures of the targets functions, which is 
sad :-(

> If we decide to provide using-decl results from index, I think we should make 
> sure the code completion information (e.g. signature) is correct.

The problem is that using-decls have multiple signatures. They can introduce 
more than one name into the scope, so the question is which one should we pick 
and how should we store them.
In any case, it feels like any solution we can come up with would require 
storing using declarations in the index in one form or the other, so this patch 
definitely makes sense: it gives us hooks we can use to handle usings in clangd.


Repository:
  rCTE Clang Tools Extra

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D58341/new/

https://reviews.llvm.org/D58341



_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to