Torque2D Reference

- Main Page
- Related Pages
- Modules
- Namespaces
- Classes

- Class List
- Class Index
- Class Hierarchy
- Class Members

Public Member Functions | Public Attributes | List of all members
StmtNode Struct Referenceabstract

`#include <ast.h>`

Inheritance diagram for StmtNode:

## Public Member Functions
| StmtNode ()
next Accessors
void | append (StmtNode *next)
StmtNode * | getNext ()
Breaking
void | addBreakCount ()
void | addBreakLine (U32 ip)
Compilation
virtual U32 | precompileStmt (U32 loopCount)=0
virtual U32 | compileStmt (U32 *codeStream, U32 ip, U32 continuePoint, U32 breakPoint)=0
virtual void | setPackage (StringTableEntry packageName)

## Public Attributes
StmtNode * | next
| Next entry in parse tree. More...
Debug Info
StringTableEntry | dbgFileName
| Name of file this node is associated with. More...
S32 | dbgLineNumber

## Detailed Description

Representation of a node for the scripting language parser.

When the scripting language is evaluated, it is turned from a string representation, into a parse tree, thence into byte code, which is ultimately interpreted by the VM.

This is the base class for the nodes in the parse tree. There are a great many subclasses, each representing a different language construct.

## Constructor & Destructor Documentation

StmtNode | ( |  | ) |

## Member Function Documentation

void addBreakCount | ( |  | ) |

void addBreakLine | ( | U32 | ip | ) |

void append | ( | StmtNode * | next | ) |

virtual U32 compileStmt | ( | U32 * | codeStream,
|  | U32 | ip,
|  | U32 | continuePoint,
|  | U32 | breakPoint
| ) |  |
| pure virtual

Implemented in FunctionDeclStmtNode, TTagSetStmtNode, LoopStmtNode, IfStmtNode, ReturnStmtNode, ExprNode, ContinueStmtNode, and BreakStmtNode.

StmtNode* getNext | ( |  | ) |
| inline

virtual U32 precompileStmt | ( | U32 | loopCount | ) |
| pure virtual

Implemented in FunctionDeclStmtNode, TTagSetStmtNode, LoopStmtNode, IfStmtNode, ReturnStmtNode, ExprNode, ContinueStmtNode, and BreakStmtNode.

void setPackage | ( | StringTableEntry | packageName | ) |
| virtual

Reimplemented in FunctionDeclStmtNode.

## Member Data Documentation

StringTableEntry dbgFileName

Name of file this node is associated with.

S32 dbgLineNumber

Line number this node is associated with.

StmtNode* next

Next entry in parse tree.

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

- console/ast.h
- console/astNodes.cc