clang 20.0.0git
Public Member Functions | Public Attributes | List of all members
clang::interp::LocalScope< Emitter > Class Template Reference

Generic scope for local variables. More...

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

Inheritance diagram for clang::interp::LocalScope< Emitter >:
Inheritance graph
[legend]

Public Member Functions

 LocalScope (Compiler< Emitter > *Ctx)
 
 LocalScope (Compiler< Emitter > *Ctx, const ValueDecl *VD)
 
 ~LocalScope () override
 Emit a Destroy op for this scope.
 
void emitDestruction () override
 Overriden to support explicit destruction.
 
bool destroyLocals (const Expr *E=nullptr) override
 Explicit destruction of local variables.
 
void addLocal (const Scope::Local &Local) override
 
bool emitDestructors (const Expr *E=nullptr) override
 
void removeStoredOpaqueValues ()
 
void removeIfStoredOpaqueValue (const Scope::Local &Local)
 
- Public Member Functions inherited from clang::interp::VariableScope< Emitter >
 VariableScope (Compiler< Emitter > *Ctx, const ValueDecl *VD)
 
virtual ~VariableScope ()
 
void add (const Scope::Local &Local, bool IsExtended)
 
virtual void addLocal (const Scope::Local &Local)
 
virtual void addExtended (const Scope::Local &Local)
 
void addExtended (const Scope::Local &Local, const ValueDecl *ExtendingDecl)
 
virtual void emitDestruction ()
 
virtual bool emitDestructors (const Expr *E=nullptr)
 
virtual bool destroyLocals (const Expr *E=nullptr)
 
VariableScopegetParent () const
 

Public Attributes

std::optional< unsignedIdx
 Index of the scope in the chain.
 

Additional Inherited Members

- Protected Attributes inherited from clang::interp::VariableScope< Emitter >
Compiler< Emitter > * Ctx
 Compiler instance.
 
VariableScopeParent
 Link to the parent scope.
 
const ValueDeclValDecl = nullptr
 

Detailed Description

template<class Emitter>
class clang::interp::LocalScope< Emitter >

Generic scope for local variables.

Definition at line 475 of file Compiler.h.

Constructor & Destructor Documentation

◆ LocalScope() [1/2]

template<class Emitter >
clang::interp::LocalScope< Emitter >::LocalScope ( Compiler< Emitter > *  Ctx)
inline

Definition at line 477 of file Compiler.h.

◆ LocalScope() [2/2]

template<class Emitter >
clang::interp::LocalScope< Emitter >::LocalScope ( Compiler< Emitter > *  Ctx,
const ValueDecl VD 
)
inline

Definition at line 478 of file Compiler.h.

◆ ~LocalScope()

template<class Emitter >
clang::interp::LocalScope< Emitter >::~LocalScope ( )
inlineoverride

Emit a Destroy op for this scope.

Definition at line 482 of file Compiler.h.

Member Function Documentation

◆ addLocal()

template<class Emitter >
void clang::interp::LocalScope< Emitter >::addLocal ( const Scope::Local Local)
inlineoverridevirtual

Reimplemented from clang::interp::VariableScope< Emitter >.

Definition at line 509 of file Compiler.h.

Referenced by clang::interp::DeclScope< Emitter >::addExtended().

◆ destroyLocals()

template<class Emitter >
bool clang::interp::LocalScope< Emitter >::destroyLocals ( const Expr E = nullptr)
inlineoverridevirtual

◆ emitDestruction()

template<class Emitter >
void clang::interp::LocalScope< Emitter >::emitDestruction ( )
inlineoverridevirtual

Overriden to support explicit destruction.

Reimplemented from clang::interp::VariableScope< Emitter >.

Definition at line 490 of file Compiler.h.

◆ emitDestructors()

template<class Emitter >
bool clang::interp::LocalScope< Emitter >::emitDestructors ( const Expr E = nullptr)
inlineoverridevirtual

Reimplemented from clang::interp::VariableScope< Emitter >.

Definition at line 519 of file Compiler.h.

References E.

◆ removeIfStoredOpaqueValue()

template<class Emitter >
void clang::interp::LocalScope< Emitter >::removeIfStoredOpaqueValue ( const Scope::Local Local)
inline

Definition at line 549 of file Compiler.h.

◆ removeStoredOpaqueValues()

template<class Emitter >
void clang::interp::LocalScope< Emitter >::removeStoredOpaqueValues ( )
inline

Definition at line 540 of file Compiler.h.

Member Data Documentation

◆ Idx

template<class Emitter >
std::optional<unsigned> clang::interp::LocalScope< Emitter >::Idx

Index of the scope in the chain.

Definition at line 559 of file Compiler.h.


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