diff options
Diffstat (limited to 'include/lldb/Symbol/DeclVendor.h')
-rw-r--r-- | include/lldb/Symbol/DeclVendor.h | 42 |
1 files changed, 22 insertions, 20 deletions
diff --git a/include/lldb/Symbol/DeclVendor.h b/include/lldb/Symbol/DeclVendor.h index d1ccb4191cbc6..9c10fe1177fba 100644 --- a/include/lldb/Symbol/DeclVendor.h +++ b/include/lldb/Symbol/DeclVendor.h @@ -1,9 +1,8 @@ //===-- DeclVendor.h --------------------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. +// See https://llvm.org/LICENSE.txt for license information. +// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // //===----------------------------------------------------------------------===// @@ -19,54 +18,57 @@ namespace lldb_private { -//---------------------------------------------------------------------- // The Decl vendor class is intended as a generic interface to search for named // declarations that are not necessarily backed by a specific symbol file. -//---------------------------------------------------------------------- class DeclVendor { public: - //------------------------------------------------------------------ // Constructors and Destructors - //------------------------------------------------------------------ DeclVendor() {} virtual ~DeclVendor() {} - //------------------------------------------------------------------ /// Look up the set of Decls that the DeclVendor currently knows about /// matching a given name. /// - /// @param[in] name + /// \param[in] name /// The name to look for. /// - /// @param[in] append + /// \param[in] append /// If true, FindDecls will clear "decls" when it starts. /// - /// @param[in] max_matches + /// \param[in] max_matches /// The maximum number of Decls to return. UINT32_MAX means "as /// many as possible." /// - /// @return + /// \return /// The number of Decls added to decls; will not exceed /// max_matches. - //------------------------------------------------------------------ - virtual uint32_t FindDecls(const ConstString &name, bool append, + virtual uint32_t FindDecls(ConstString name, bool append, uint32_t max_matches, std::vector<clang::NamedDecl *> &decls) = 0; - //------------------------------------------------------------------ + /// Look up the types that the DeclVendor currently knows about matching a + /// given name. + /// + /// \param[in] name + /// The name to look for. + /// + /// \param[in] max_matches + // The maximum number of matches. UINT32_MAX means "as many as possible". + /// + /// \return + /// The vector of CompilerTypes that was found. + std::vector<CompilerType> FindTypes(ConstString name, uint32_t max_matches); + /// Interface for ExternalASTMerger. Returns an ImporterSource /// allowing type completion. /// - /// @return + /// \return /// An ImporterSource for this DeclVendor. - //------------------------------------------------------------------ virtual clang::ExternalASTMerger::ImporterSource GetImporterSource() = 0; private: - //------------------------------------------------------------------ // For DeclVendor only - //------------------------------------------------------------------ DISALLOW_COPY_AND_ASSIGN(DeclVendor); }; |