ilya-biryukov added inline comments.

================
Comment at: clang-tools-extra/clangd/FindTarget.cpp:415
 
 Optional<ReferenceLoc> refInDecl(const Decl *D) {
   struct Visitor : ConstDeclVisitor<Visitor> {
----------------
hokein wrote:
> ilya-biryukov wrote:
> > This should return `SmallVector<ReferenceLoc, 2>` now, some declarations 
> > can have both decl and non-decl references.
> Can you give some examples? It seems that non-decl references are handled by 
> other `refIn*` functions.
> 
> ```
> int Foo = OtherBar; // OtherBar is captured at the momment.
> ```
```
namespace $1[[a]] = $2[[std]];
```

`$1` is a declaration of a namespace alias.
`$2` is a reference to namespace std.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D68977



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

Reply via email to