sun::ast::ForExprAST
class · Source (opens in a new tab)
class sun::ast::ForExprAST : public sun::ast::ExprASTA for loop with its initialization, condition, update, and body.
Inherits
- sun::ast::ExprAST (public)
Public Functions
- ForExprAST
- bodySlot
- dotLabel
- forEachChildSlot
- getBody
- getCondition
- getIncrement
- getInit
- getType
- toString
ForExprAST
public · function · Source (opens in a new tab)
sun::ast::ForExprAST::ForExprAST(std::unique_ptr< ExprAST > Init, std::unique_ptr< ExprAST > Condition, std::unique_ptr< ExprAST > Increment, std::unique_ptr< ExprAST > Body)Creates this syntax node and takes ownership of any supplied child expressions.
Related: ExprAST
bodySlot
public · function · Source (opens in a new tab)
std::unique_ptr< ExprAST > & sun::ast::ForExprAST::bodySlot()Mutable body slot for LoweringPass block normalization.
Related: ExprAST
dotLabel
public · function · Source (opens in a new tab)
std::string sun::ast::ForExprAST::dotLabel() const overrideReturns the node label used in syntax-tree graph visualizations.
forEachChildSlot
public · function · Source (opens in a new tab)
void sun::ast::ForExprAST::forEachChildSlot(const ChildSlotFn &fn) overrideVisits replaceable child expressions so tree passes can rewrite them in place.
Related: ChildSlotFn
getBody
public · function · Source (opens in a new tab)
const ExprAST * sun::ast::ForExprAST::getBody() constProvides access to the expressions that make up the body.
Related: ExprAST
getCondition
public · function · Source (opens in a new tab)
const ExprAST * sun::ast::ForExprAST::getCondition() constReturns the condition expression.
Related: ExprAST
getIncrement
public · function · Source (opens in a new tab)
const ExprAST * sun::ast::ForExprAST::getIncrement() constReturns the loop update expression.
Related: ExprAST
getInit
public · function · Source (opens in a new tab)
const ExprAST * sun::ast::ForExprAST::getInit() constReturns the loop initialization expression.
Related: ExprAST
getType
public · function · Source (opens in a new tab)
ASTNodeType sun::ast::ForExprAST::getType() const overrideReturns the syntax-node kind used to dispatch tree visitors.
Related: ASTNodeType
toString
public · function · Source (opens in a new tab)
std::string sun::ast::ForExprAST::toString() const overrideReturns a readable representation for diagnostics and debugging.
Private Fields
Body
private · variable · Source (opens in a new tab)
std::unique_ptr<ExprAST> sun::ast::ForExprAST::BodyNo documentation comment.
Related: ExprAST
Condition
private · variable · Source (opens in a new tab)
std::unique_ptr<ExprAST> sun::ast::ForExprAST::ConditionNo documentation comment.
Related: ExprAST
Increment
private · variable · Source (opens in a new tab)
std::unique_ptr<ExprAST> sun::ast::ForExprAST::IncrementNo documentation comment.
Related: ExprAST
Init
private · variable · Source (opens in a new tab)
std::unique_ptr<ExprAST> sun::ast::ForExprAST::InitNo documentation comment.
Related: ExprAST