Zen
A cross-platform functional programming language
|
AST Node for a continuation implementation. More...
#include <Ast.hpp>
Public Member Functions | |
ContinuationImplItem (const int &idx, const FunctionDef &fdef, const Ast::ClosureList &closureList, const ReturnClosure &retnClosure) | |
Default constructor. | |
z::string | getUniqueName (const z::string &sep) const |
Returns the unique name for this implementation item. | |
const Ast::ClosureList & | getClosureList () const |
Returns the closure list for this continuation. | |
const Ast::ReturnClosure & | getReturnClosure () const |
Returns the return closure for this continuation. | |
const VariableRefList & | getXRefList () const |
Returns the external reference list for this continuation. | |
void | setXRefList (const VariableRefList &xRefList) |
Set the closure list for this continuation. | |
const InitClosure & | getInitClosure () const |
Returns a reference to the first closure in the list. | |
const Invoker * | hasRoutineCall () const |
Returns a pointer to the first invoker in the list, if it is a routine. | |
void | visitClosureList (Closure::Visitor &visitor) const |
Abstract visitor function. | |
virtual const Ast::FunctionImplItem & | getFunctionImplItem () const |
Returns a reference to this if this is a FunctionImplItem, else throws exception. | |
Private Member Functions | |
const InitClosure * | getInitClosureP () const |
Returns a pointer to the first closure in the list. | |
virtual void | visit (ImplItem::Visitor &visitor) const |
Abstract visitor function. | |
Private Attributes | |
VariableRefList | _xRefList |
The external reference list. | |
const Ast::ClosureList & | _closureList |
The closure list. | |
const ReturnClosure & | _retnClosure |
The return closure. |
AST Node for a continuation implementation.
Figure out how to merge implementation items and blocks
Redesign to replace idx with full name created by the factory itself, and eliminate getUniqueName()
ContinuationImplItem | ( | const int & | idx, |
const FunctionDef & | fdef, | ||
const Ast::ClosureList & | closureList, | ||
const ReturnClosure & | retnClosure | ||
) | [inline] |
Default constructor.
idx | The index of this item in the list of impl items. |
fdef | The function definition implemented in this item. |
closureList | The list of closures in this continuation. |
retnClosure | The return closure for this continuation. |
const Ast::ClosureList& getClosureList | ( | ) | const [inline] |
Returns the closure list for this continuation.
virtual const Ast::FunctionImplItem& getFunctionImplItem | ( | ) | const [inline, virtual] |
Returns a reference to this if this is a FunctionImplItem, else throws exception.
Implements ImplItem.
const InitClosure& getInitClosure | ( | ) | const [inline] |
Returns a reference to the first closure in the list.
const InitClosure* getInitClosureP | ( | ) | const [inline, private] |
Returns a pointer to the first closure in the list.
const Ast::ReturnClosure& getReturnClosure | ( | ) | const [inline] |
Returns the return closure for this continuation.
Returns the unique name for this implementation item.
sep | The separator |
const VariableRefList& getXRefList | ( | ) | const [inline] |
Returns the external reference list for this continuation.
const Invoker* hasRoutineCall | ( | ) | const [inline] |
Returns a pointer to the first invoker in the list, if it is a routine.
void setXRefList | ( | const VariableRefList & | xRefList | ) | [inline] |
Set the closure list for this continuation.
xRefList | The closure list. |
void visit | ( | ImplItem::Visitor & | visitor | ) | const [private, virtual] |
void visitClosureList | ( | Closure::Visitor & | visitor | ) | const |
Abstract visitor function.
visitor | The visitor object. |