comma::ForStmt Class Reference

This node represents the "for" loop iteration scheme. More...

#include <Stmt.h>

Inheritance diagram for comma::ForStmt:
Inheritance graph
[legend]
Collaboration diagram for comma::ForStmt:
Collaboration graph
[legend]

List of all members.

Public Member Functions

 ForStmt (Location loc, LoopDecl *iterationDecl, DSTDefinition *control)
 Constructs a for-loop statement over the given declaration and discrete subtype definition node.
bool isReversed () const
 Returns true if the controlling scheme is reversed.
void markAsReversed ()
 Marks that this loop is reversed.



const LoopDeclgetLoopDecl () const
 Returns the LoopDecl corresponding to the iteration value of this loop.
LoopDeclgetLoopDecl ()
 Returns the LoopDecl corresponding to the iteration value of this loop.
const DSTDefinitiongetControl () const
 Returns the discrete subtype definition controlling this loop.
DSTDefinitiongetControl ()
 Returns the LoopDecl corresponding to the iteration value of this loop.
const DiscreteTypegetControlType () const
DiscreteTypegetControlType ()
 Returns the LoopDecl corresponding to the iteration value of this loop.
const StmtSequencegetBody () const
StmtSequencegetBody ()
 Returns the LoopDecl corresponding to the iteration value of this loop.

Static Public Member Functions

static bool classof (const ForStmt *node)
 Support isa and dyn_cast.
static bool classof (const Ast *node)

Detailed Description

This node represents the "for" loop iteration scheme.

Definition at line 452 of file Stmt.h.


Constructor & Destructor Documentation

ForStmt::ForStmt ( Location  loc,
LoopDecl iterationDecl,
DSTDefinition control 
)

Constructs a for-loop statement over the given declaration and discrete subtype definition node.

Definition at line 102 of file Stmt.cpp.


Member Function Documentation

static bool comma::ForStmt::classof ( const Ast node  )  [inline, static]

Reimplemented from comma::Stmt.

Definition at line 497 of file Stmt.h.

static bool comma::ForStmt::classof ( const ForStmt node  )  [inline, static]

Support isa and dyn_cast.

Reimplemented from comma::Stmt.

Definition at line 496 of file Stmt.h.

StmtSequence* comma::ForStmt::getBody (  )  [inline]

Returns the LoopDecl corresponding to the iteration value of this loop.

Definition at line 492 of file Stmt.h.

const StmtSequence* comma::ForStmt::getBody (  )  const [inline]

Retururns the StmtSequence forming the body of this loop.

Initially, this sequence is empty and must be populated via explicit calls to StmtSequence::addStmt().

Definition at line 491 of file Stmt.h.

DSTDefinition* comma::ForStmt::getControl (  )  [inline]

Returns the LoopDecl corresponding to the iteration value of this loop.

Definition at line 468 of file Stmt.h.

const DSTDefinition* comma::ForStmt::getControl (  )  const [inline]

Returns the discrete subtype definition controlling this loop.

Definition at line 467 of file Stmt.h.

DiscreteType* comma::ForStmt::getControlType (  )  [inline]

Returns the LoopDecl corresponding to the iteration value of this loop.

Definition at line 477 of file Stmt.h.

const DiscreteType* comma::ForStmt::getControlType (  )  const [inline]

Returns the controlling subtype of this loop. All loop controls have an associated type (the type of the associated LoopDecl).

Definition at line 474 of file Stmt.h.

LoopDecl* comma::ForStmt::getLoopDecl (  )  [inline]

Returns the LoopDecl corresponding to the iteration value of this loop.

Definition at line 462 of file Stmt.h.

const LoopDecl* comma::ForStmt::getLoopDecl (  )  const [inline]

Returns the LoopDecl corresponding to the iteration value of this loop.

Definition at line 461 of file Stmt.h.

bool comma::ForStmt::isReversed (  )  const [inline]

Returns true if the controlling scheme is reversed.

Definition at line 481 of file Stmt.h.

void comma::ForStmt::markAsReversed (  )  [inline]

Marks that this loop is reversed.

Definition at line 484 of file Stmt.h.


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

Generated on 1 Feb 2010 for Comma by  doxygen 1.6.1