clang-tools 20.0.0git
Namespaces | Functions
Rename.cpp File Reference
#include "refactor/Rename.h"
#include "AST.h"
#include "FindTarget.h"
#include "ParsedAST.h"
#include "Selection.h"
#include "SourceCode.h"
#include "index/SymbolCollector.h"
#include "support/Logger.h"
#include "support/Trace.h"
#include "clang/AST/ASTContext.h"
#include "clang/AST/ASTTypeTraits.h"
#include "clang/AST/Decl.h"
#include "clang/AST/DeclCXX.h"
#include "clang/AST/DeclObjC.h"
#include "clang/AST/DeclTemplate.h"
#include "clang/AST/ParentMapContext.h"
#include "clang/AST/Stmt.h"
#include "clang/Basic/CharInfo.h"
#include "clang/Basic/LLVM.h"
#include "clang/Basic/SourceLocation.h"
#include "clang/Tooling/Syntax/Tokens.h"
#include "llvm/ADT/STLExtras.h"
#include "llvm/ADT/StringExtras.h"
#include "llvm/Support/Casting.h"
#include "llvm/Support/Error.h"
#include "llvm/Support/FormatVariadic.h"
#include "llvm/Support/JSON.h"
#include <algorithm>
#include <optional>

Go to the source code of this file.

Namespaces

namespace  clang
 ===– Representation.cpp - ClangDoc Representation --------—*- C++ -*-===//
 
namespace  clang::clangd
 FIXME: Skip testing on windows temporarily due to the different escaping code mode.
 

Functions

bool clang::clangd::operator== (const SymbolRange &LHS, const SymbolRange &RHS)
 
bool clang::clangd::operator!= (const SymbolRange &LHS, const SymbolRange &RHS)
 
bool clang::clangd::operator< (const SymbolRange &LHS, const SymbolRange &RHS)
 
llvm::Expected< RenameResult > clang::clangd::rename (const RenameInputs &RInputs)
 Renames all occurrences of the symbol.
 
llvm::Expected< Edit > clang::clangd::buildRenameEdit (llvm::StringRef AbsFilePath, llvm::StringRef InitialCode, std::vector< SymbolRange > Occurrences, llvm::ArrayRef< llvm::StringRef > NewNames)
 Generates rename edits that replaces all given occurrences with the NewName.
 
std::optional< std::vector< SymbolRange > > clang::clangd::adjustRenameRanges (llvm::StringRef DraftCode, llvm::StringRef Identifier, std::vector< Range > Indexed, const LangOptions &LangOpts, std::optional< Selector > Selector)
 Adjusts indexed occurrences to match the current state of the file.
 
std::optional< std::vector< SymbolRange > > clang::clangd::getMappedRanges (ArrayRef< Range > Indexed, ArrayRef< SymbolRange > Lexed)
 Calculates the lexed occurrences that the given indexed occurrences map to.
 
size_t clang::clangd::renameRangeAdjustmentCost (ArrayRef< Range > Indexed, ArrayRef< SymbolRange > Lexed, ArrayRef< size_t > MappedIndex)
 Evaluates how good the mapped result is.
 

Variable Documentation

◆ Details

std::string Details

Definition at line 475 of file Rename.cpp.

◆ K

Kind K