clang-tools  10.0.0svn
Namespaces | Macros | Functions
Quality.cpp File Reference
#include "Quality.h"
#include "AST.h"
#include "FileDistance.h"
#include "SourceCode.h"
#include "URI.h"
#include "index/Symbol.h"
#include "clang/AST/ASTContext.h"
#include "clang/AST/Decl.h"
#include "clang/AST/DeclCXX.h"
#include "clang/AST/DeclTemplate.h"
#include "clang/AST/DeclVisitor.h"
#include "clang/Basic/CharInfo.h"
#include "clang/Basic/SourceManager.h"
#include "clang/Sema/CodeCompleteConsumer.h"
#include "llvm/ADT/ArrayRef.h"
#include "llvm/ADT/SmallString.h"
#include "llvm/ADT/SmallVector.h"
#include "llvm/ADT/StringExtras.h"
#include "llvm/ADT/StringRef.h"
#include "llvm/Support/Casting.h"
#include "llvm/Support/FormatVariadic.h"
#include "llvm/Support/MathExtras.h"
#include "llvm/Support/raw_ostream.h"
#include <algorithm>
#include <cmath>
Include dependency graph for Quality.cpp:

Go to the source code of this file.

Namespaces

 clang
 ===– Representation.cpp - ClangDoc Representation --------—*- C++ -*-===//
 
 clang::clangd
 

Macros

#define MAP(DeclType, Category)
 

Functions

static bool clang::clangd::isReserved (llvm::StringRef Name)
 
static bool clang::clangd::hasDeclInMainFile (const Decl &D)
 
static bool clang::clangd::hasUsingDeclInMainFile (const CodeCompletionResult &R)
 
static SymbolQualitySignals::SymbolCategory clang::clangd::categorize (const NamedDecl &ND)
 
static SymbolQualitySignals::SymbolCategory clang::clangd::categorize (const CodeCompletionResult &R)
 
static SymbolQualitySignals::SymbolCategory clang::clangd::categorize (const index::SymbolInfo &D)
 
static bool clang::clangd::isInstanceMember (const NamedDecl *ND)
 
static bool clang::clangd::isInstanceMember (const index::SymbolInfo &D)
 
llvm::raw_ostream & clang::clangd::operator<< (llvm::raw_ostream &OS, const SymbolQualitySignals &S)
 
static SymbolRelevanceSignals::AccessibleScope clang::clangd::computeScope (const NamedDecl *D)
 
static std::pair< float, unsigned > clang::clangd::uriProximity (llvm::StringRef SymbolURI, URIDistance *D)
 
static float clang::clangd::scopeBoost (ScopeDistance &Distance, llvm::Optional< llvm::StringRef > SymbolScope)
 
static llvm::Optional< llvm::StringRef > clang::clangd::wordMatching (llvm::StringRef Name, const llvm::StringSet<> *ContextWords)
 
llvm::raw_ostream & clang::clangd::operator<< (llvm::raw_ostream &OS, const SymbolRelevanceSignals &S)
 
float clang::clangd::evaluateSymbolAndRelevance (float SymbolQuality, float SymbolRelevance)
 Combine symbol quality and relevance into a single score. More...
 
static uint32_t clang::clangd::encodeFloat (float F)
 
std::string clang::clangd::sortText (float Score, llvm::StringRef Tiebreak="")
 Returns a string that sorts in the same order as (-Score, Tiebreak), for LSP. More...
 
llvm::raw_ostream & clang::clangd::operator<< (llvm::raw_ostream &OS, const SignatureQualitySignals &S)
 

Macro Definition Documentation

◆ MAP

#define MAP (   DeclType,
  Category 
)
Value:
SymbolQualitySignals::SymbolCategory Visit##DeclType(const DeclType *) { \
return SymbolQualitySignals::Category; \
}

Referenced by clang::clangd::categorize().