[PATCH] D139458: [clangd] Full support for #import insertions

David Goldman via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Tue Jan 3 20:11:27 PST 2023


dgoldman added inline comments.


================
Comment at: clang-tools-extra/clangd/ParsedAST.h:88
   /// (These should be const, but RecursiveASTVisitor requires Decl*).
-  ArrayRef<Decl *> getLocalTopLevelDecls();
+  ArrayRef<Decl *> getLocalTopLevelDecls() const;
 
----------------
kadircet wrote:
> can you rather introduce a new overload that returns `ArrayRef<const Decl*>`
Did you mean an overload with `ArrayRef<const Decl *> getLocalTopLevelDecls() const;`? ASTSignals gets a const ParsedAST &, unless you want me to const cast instead?


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D139458



More information about the cfe-commits mailing list