clang 20.0.0git
Typedefs | Functions
RangeSelector.cpp File Reference
#include "clang/Tooling/Transformer/RangeSelector.h"
#include "clang/AST/Expr.h"
#include "clang/AST/TypeLoc.h"
#include "clang/ASTMatchers/ASTMatchFinder.h"
#include "clang/Basic/SourceLocation.h"
#include "clang/Lex/Lexer.h"
#include "clang/Tooling/Transformer/SourceCode.h"
#include "llvm/ADT/StringRef.h"
#include "llvm/Support/Errc.h"
#include "llvm/Support/Error.h"
#include <string>
#include <utility>
#include <vector>

Go to the source code of this file.

Typedefs

using MatchResult = MatchFinder::MatchResult
 

Functions

static Error invalidArgumentError (Twine Message)
 
static Error typeError (StringRef ID, const ASTNodeKind &Kind)
 
static Error typeError (StringRef ID, const ASTNodeKind &Kind, Twine ExpectedType)
 
static Error missingPropertyError (StringRef ID, Twine Description, StringRef Property)
 
static Expected< DynTypedNodegetNode (const ast_matchers::BoundNodes &Nodes, StringRef ID)
 
static SourceLocation findPreviousTokenStart (SourceLocation Start, const SourceManager &SM, const LangOptions &LangOpts)
 
static SourceLocation findPreviousTokenKind (SourceLocation Start, const SourceManager &SM, const LangOptions &LangOpts, tok::TokenKind TK)
 

Typedef Documentation

◆ MatchResult

Definition at line 30 of file RangeSelector.cpp.

Function Documentation

◆ findPreviousTokenKind()

static SourceLocation findPreviousTokenKind ( SourceLocation  Start,
const SourceManager SM,
const LangOptions LangOpts,
tok::TokenKind  TK 
)
static

◆ findPreviousTokenStart()

static SourceLocation findPreviousTokenStart ( SourceLocation  Start,
const SourceManager SM,
const LangOptions LangOpts 
)
static

◆ getNode()

static Expected< DynTypedNode > getNode ( const ast_matchers::BoundNodes Nodes,
StringRef  ID 
)
static

◆ invalidArgumentError()

static Error invalidArgumentError ( Twine  Message)
static

◆ missingPropertyError()

static Error missingPropertyError ( StringRef  ID,
Twine  Description,
StringRef  Property 
)
static

Definition at line 48 of file RangeSelector.cpp.

References invalidArgumentError(), and clang::Property.

Referenced by clang::transformer::name().

◆ typeError() [1/2]

static Error typeError ( StringRef  ID,
const ASTNodeKind Kind 
)
static

Definition at line 36 of file RangeSelector.cpp.

References invalidArgumentError().

Referenced by clang::transformer::member(), and clang::transformer::name().

◆ typeError() [2/2]

static Error typeError ( StringRef  ID,
const ASTNodeKind Kind,
Twine  ExpectedType 
)
static

Definition at line 41 of file RangeSelector.cpp.

References invalidArgumentError().