clang 19.0.0git
Classes | Namespaces | Enumerations | Functions
CodeCompleteConsumer.h File Reference
#include "clang-c/Index.h"
#include "clang/AST/Type.h"
#include "clang/Basic/LLVM.h"
#include "clang/Lex/MacroInfo.h"
#include "clang/Sema/CodeCompleteOptions.h"
#include "clang/Sema/DeclSpec.h"
#include "llvm/ADT/ArrayRef.h"
#include "llvm/ADT/DenseMap.h"
#include "llvm/ADT/SmallPtrSet.h"
#include "llvm/ADT/SmallVector.h"
#include "llvm/ADT/StringRef.h"
#include "llvm/Support/Allocator.h"
#include "llvm/Support/type_traits.h"
#include <cassert>
#include <memory>
#include <optional>
#include <string>
#include <utility>

Go to the source code of this file.

Classes

class  clang::CodeCompletionContext
 The context in which code completion occurred, so that the code-completion consumer can process the results accordingly. More...
 
class  clang::CodeCompletionString
 A "string" used to describe how code completion can be performed for an entity. More...
 
struct  clang::CodeCompletionString::Chunk
 One piece of the code completion string. More...
 
class  clang::CodeCompletionAllocator
 An allocator used specifically for the purpose of code completion. More...
 
class  clang::GlobalCodeCompletionAllocator
 Allocator for a cached set of global code completions. More...
 
class  clang::CodeCompletionTUInfo
 
class  clang::CodeCompletionBuilder
 A builder class used to construct new code-completion strings. More...
 
class  clang::CodeCompletionResult
 Captures a result of code completion. More...
 
class  clang::CodeCompleteConsumer
 Abstract interface for a consumer of code-completion information. More...
 
class  clang::CodeCompleteConsumer::OverloadCandidate
 
class  clang::PrintingCodeCompleteConsumer
 A simple code-completion consumer that prints the results it receives in a simple format. More...
 

Namespaces

namespace  clang
 The JSON file list parser is used to communicate input to InstallAPI.
 

Enumerations

enum  {
  clang::CCP_NextInitializer = 7 , clang::CCP_EnumInCase = 7 , clang::CCP_SuperCompletion = 20 , clang::CCP_LocalDeclaration = 34 ,
  clang::CCP_MemberDeclaration = 35 , clang::CCP_Keyword = 40 , clang::CCP_CodePattern = 40 , clang::CCP_Declaration = 50 ,
  clang::CCP_Type = CCP_Declaration , clang::CCP_Constant = 65 , clang::CCP_Macro = 70 , clang::CCP_NestedNameSpecifier = 75 ,
  clang::CCP_Unlikely = 80 , clang::CCP_ObjC_cmd = CCP_Unlikely
}
 Default priority values for code-completion results based on their kind. More...
 
enum  {
  clang::CCD_InBaseClass = 2 , clang::CCD_ObjectQualifierMatch = -1 , clang::CCD_SelectorMatch = -3 , clang::CCD_bool_in_ObjC = 1 ,
  clang::CCD_ProbablyNotObjCCollection = 15 , clang::CCD_MethodAsProperty = 2 , clang::CCD_BlockPropertySetter = 3
}
 Priority value deltas that are added to code-completion results based on the context of the result. More...
 
enum  { clang::CCF_ExactTypeMatch = 4 , clang::CCF_SimilarTypeMatch = 2 }
 Priority value factors by which we will divide or multiply the priority of a code-completion result. More...
 
enum  clang::SimplifiedTypeClass {
  clang::STC_Arithmetic , clang::STC_Array , clang::STC_Block , clang::STC_Function ,
  clang::STC_ObjectiveC , clang::STC_Other , clang::STC_Pointer , clang::STC_Record ,
  clang::STC_Void
}
 A simplified classification of types used when determining "similar" types for code completion. More...
 

Functions

SimplifiedTypeClass clang::getSimplifiedTypeClass (CanQualType T)
 Determine the simplified type class of the given canonical type.
 
QualType clang::getDeclUsageType (ASTContext &C, const NamedDecl *ND)
 Determine the type that this declaration will have if it is used as a type or in an expression.
 
unsigned clang::getMacroUsagePriority (StringRef MacroName, const LangOptions &LangOpts, bool PreferredTypeIsPointer=false)
 Determine the priority to be given to a macro code completion result with the given name.
 
CXCursorKind clang::getCursorKindForDecl (const Decl *D)
 Determine the libclang cursor kind associated with the given declaration.
 
llvm::StringRef clang::getCompletionKindString (CodeCompletionContext::Kind Kind)
 Get string representation of Kind, useful for debugging.
 
bool clang::operator< (const CodeCompletionResult &X, const CodeCompletionResult &Y)
 
bool clang::operator> (const CodeCompletionResult &X, const CodeCompletionResult &Y)
 
bool clang::operator<= (const CodeCompletionResult &X, const CodeCompletionResult &Y)
 
bool clang::operator>= (const CodeCompletionResult &X, const CodeCompletionResult &Y)
 
const RawCommentclang::getCompletionComment (const ASTContext &Ctx, const NamedDecl *Decl)
 Get the documentation comment used to produce CodeCompletionString::BriefComment for RK_Declaration.
 
const RawCommentclang::getPatternCompletionComment (const ASTContext &Ctx, const NamedDecl *Decl)
 Get the documentation comment used to produce CodeCompletionString::BriefComment for RK_Pattern.
 
const RawCommentclang::getParameterComment (const ASTContext &Ctx, const CodeCompleteConsumer::OverloadCandidate &Result, unsigned ArgIndex)
 Get the documentation comment used to produce CodeCompletionString::BriefComment for OverloadCandidate.