diff options
author | Kadir Cetinkaya <kadircet@google.com> | 2019-02-11 13:02:21 +0000 |
---|---|---|
committer | Kadir Cetinkaya <kadircet@google.com> | 2019-02-11 13:02:21 +0000 |
commit | 0468fc0b8d7193f68432a21148eea9444df61712 (patch) | |
tree | 176671f02f96ca57a2b51d5d21a585d8c8240a74 /clang/lib/Index/IndexingContext.cpp | |
parent | cf13bfee0012424e3364672c598185a4f628c089 (diff) | |
download | bcm5719-llvm-0468fc0b8d7193f68432a21148eea9444df61712.tar.gz bcm5719-llvm-0468fc0b8d7193f68432a21148eea9444df61712.zip |
[clang][Index] Add a knob to index function parameters in declarations
Summary:
Parameters in declarations are useful for clangd, so that we can
provide symbol information for them as well. It also helps clangd to be
consistent whether a function's definition is accessible or not.
Reviewers: hokein, akyrtzi
Subscribers: ilya-biryukov, ioeric, arphaman, cfe-commits
Tags: #clang
Differential Revision: https://reviews.llvm.org/D57949
llvm-svn: 353695
Diffstat (limited to 'clang/lib/Index/IndexingContext.cpp')
-rw-r--r-- | clang/lib/Index/IndexingContext.cpp | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/clang/lib/Index/IndexingContext.cpp b/clang/lib/Index/IndexingContext.cpp index 0bbd739d741..3d2d7d4ff02 100644 --- a/clang/lib/Index/IndexingContext.cpp +++ b/clang/lib/Index/IndexingContext.cpp @@ -40,6 +40,10 @@ bool IndexingContext::shouldIndexImplicitInstantiation() const { return IndexOpts.IndexImplicitInstantiation; } +bool IndexingContext::shouldIndexParametersInDeclarations() const { + return IndexOpts.IndexParametersInDeclarations; +} + bool IndexingContext::handleDecl(const Decl *D, SymbolRoleSet Roles, ArrayRef<SymbolRelation> Relations) { |