clang 20.0.0git
Public Member Functions | List of all members
clang::interp::SourceMapper Class Referenceabstract

Interface for classes which map locations to sources. More...

#include "/home/buildbot/as-worker-4/publish-doxygen-docs/llvm-project/clang/lib/AST/ByteCode/Source.h"

Inheritance diagram for clang::interp::SourceMapper:
Inheritance graph
[legend]

Public Member Functions

virtual ~SourceMapper ()
 
virtual SourceInfo getSource (const Function *F, CodePtr PC) const =0
 Returns source information for a given PC in a function.
 
const ExprgetExpr (const Function *F, CodePtr PC) const
 Returns the expression if an opcode belongs to one, null otherwise.
 
SourceLocation getLocation (const Function *F, CodePtr PC) const
 Returns the location from which an opcode originates.
 
SourceRange getRange (const Function *F, CodePtr PC) const
 

Detailed Description

Interface for classes which map locations to sources.

Definition at line 99 of file Source.h.

Constructor & Destructor Documentation

◆ ~SourceMapper()

virtual clang::interp::SourceMapper::~SourceMapper ( )
inlinevirtual

Definition at line 101 of file Source.h.

Member Function Documentation

◆ getExpr()

const Expr * SourceMapper::getExpr ( const Function F,
CodePtr  PC 
) const

Returns the expression if an opcode belongs to one, null otherwise.

Definition at line 41 of file Source.cpp.

References E, and getSource().

Referenced by clang::interp::InterpFrame::getExpr().

◆ getLocation()

SourceLocation SourceMapper::getLocation ( const Function F,
CodePtr  PC 
) const

Returns the location from which an opcode originates.

Definition at line 47 of file Source.cpp.

References clang::interp::SourceInfo::getLoc(), and getSource().

Referenced by clang::interp::InterpFrame::getLocation().

◆ getRange()

SourceRange SourceMapper::getRange ( const Function F,
CodePtr  PC 
) const

◆ getSource()

virtual SourceInfo clang::interp::SourceMapper::getSource ( const Function F,
CodePtr  PC 
) const
pure virtual

Returns source information for a given PC in a function.

Implemented in clang::interp::EvalEmitter, and clang::interp::InterpState.

Referenced by getExpr(), getLocation(), getRange(), and clang::interp::InterpState::getSource().


The documentation for this class was generated from the following files: