Qt 4.8
Public Functions | Public Variables | List of all members
QScript::AST::VariableDeclarationList Class Reference

#include <qscriptast_p.h>

Inheritance diagram for QScript::AST::VariableDeclarationList:
QScript::AST::Node

Public Functions

virtual void accept0 (Visitor *visitor)
 
VariableDeclarationListfinish (bool readOnly)
 
 VariableDeclarationList (VariableDeclaration *decl)
 
 VariableDeclarationList (VariableDeclarationList *previous, VariableDeclaration *decl)
 
virtual ~VariableDeclarationList ()
 
- Public Functions inherited from QScript::AST::Node
void accept (Visitor *visitor)
 
virtual BinaryExpressionbinaryExpressionCast ()
 
virtual ExpressionNodeexpressionCast ()
 
 Node ()
 
virtual StatementstatementCast ()
 
virtual ~Node ()
 

Public Variables

VariableDeclarationdeclaration
 
VariableDeclarationListnext
 
- Public Variables inherited from QScript::AST::Node
int endColumn
 
int endLine
 
Kind kind
 
int startColumn
 
int startLine
 

Additional Inherited Members

- Public Types inherited from QScript::AST::Node
enum  Kind {
  Kind_Node, Kind_ExpressionNode, Kind_Statement, Kind_ThisExpression,
  Kind_IdentifierExpression, Kind_NullExpression, Kind_TrueLiteral, Kind_FalseLiteral,
  Kind_NumericLiteral, Kind_StringLiteral, Kind_RegExpLiteral, Kind_ArrayLiteral,
  Kind_ObjectLiteral, Kind_ElementList, Kind_Elision, Kind_PropertyNameAndValueList,
  Kind_PropertyName, Kind_IdentifierPropertyName, Kind_StringLiteralPropertyName, Kind_NumericLiteralPropertyName,
  Kind_ArrayMemberExpression, Kind_FieldMemberExpression, Kind_NewMemberExpression, Kind_NewExpression,
  Kind_CallExpression, Kind_ArgumentList, Kind_PostIncrementExpression, Kind_PostDecrementExpression,
  Kind_DeleteExpression, Kind_VoidExpression, Kind_TypeOfExpression, Kind_PreIncrementExpression,
  Kind_PreDecrementExpression, Kind_UnaryPlusExpression, Kind_UnaryMinusExpression, Kind_TildeExpression,
  Kind_NotExpression, Kind_BinaryExpression, Kind_ConditionalExpression, Kind_Expression,
  Kind_Block, Kind_StatementList, Kind_VariableStatement, Kind_VariableDeclarationList,
  Kind_VariableDeclaration, Kind_EmptyStatement, Kind_ExpressionStatement, Kind_IfStatement,
  Kind_DoWhileStatement, Kind_WhileStatement, Kind_ForStatement, Kind_LocalForStatement,
  Kind_ForEachStatement, Kind_LocalForEachStatement, Kind_ContinueStatement, Kind_BreakStatement,
  Kind_ReturnStatement, Kind_WithStatement, Kind_SwitchStatement, Kind_CaseBlock,
  Kind_CaseClauses, Kind_CaseClause, Kind_DefaultClause, Kind_LabelledStatement,
  Kind_ThrowStatement, Kind_TryStatement, Kind_Catch, Kind_Finally,
  Kind_FunctionDeclaration, Kind_FunctionExpression, Kind_FormalParameterList, Kind_FunctionBody,
  Kind_Program, Kind_SourceElements, Kind_SourceElement, Kind_FunctionSourceElement,
  Kind_StatementSourceElement, Kind_DebuggerStatement
}
 
- Static Public Functions inherited from QScript::AST::Node
static void acceptChild (Node *node, Visitor *visitor)
 

Detailed Description

Definition at line 888 of file qscriptast_p.h.

Constructors and Destructors

◆ VariableDeclarationList() [1/2]

QScript::AST::VariableDeclarationList::VariableDeclarationList ( VariableDeclaration decl)
inline

◆ VariableDeclarationList() [2/2]

QScript::AST::VariableDeclarationList::VariableDeclarationList ( VariableDeclarationList previous,
VariableDeclaration decl 
)
inline

Definition at line 895 of file qscriptast_p.h.

895  :
896  declaration (decl)
897  {
899  next = previous->next;
900  previous->next = this;
901  }
VariableDeclarationList * next
Definition: qscriptast_p.h:921

◆ ~VariableDeclarationList()

virtual QScript::AST::VariableDeclarationList::~VariableDeclarationList ( )
inlinevirtual

Definition at line 903 of file qscriptast_p.h.

903 {}

Functions

◆ accept0()

void QScript::AST::VariableDeclarationList::accept0 ( Visitor visitor)
virtual

Implements QScript::AST::Node.

Definition at line 428 of file qscriptast.cpp.

429 {
430  if (visitor->visit(this)) {
431  VariableDeclarationList *it = this;
432  do {
433  acceptChild(it->declaration, visitor);
434  it = it->next;
435  } while (it);
436  }
437 
438  visitor->endVisit(this);
439 }
#define it(className, varName)
static void acceptChild(Node *node, Visitor *visitor)
Definition: qscriptast_p.h:193
VariableDeclarationList(VariableDeclaration *decl)
Definition: qscriptast_p.h:891

◆ finish()

VariableDeclarationList* QScript::AST::VariableDeclarationList::finish ( bool  readOnly)
inline

Definition at line 907 of file qscriptast_p.h.

Referenced by QScriptParser::parse().

908  {
909  VariableDeclarationList *front = next;
910  next = 0;
911  if (readOnly) {
913  for (vdl = front; vdl != 0; vdl = vdl->next)
914  vdl->declaration->readOnly = true;
915  }
916  return front;
917  }
VariableDeclarationList * next
Definition: qscriptast_p.h:921
VariableDeclarationList(VariableDeclaration *decl)
Definition: qscriptast_p.h:891

Properties

◆ declaration

VariableDeclaration* QScript::AST::VariableDeclarationList::declaration

Definition at line 920 of file qscriptast_p.h.

Referenced by accept0(), and finish().

◆ next

VariableDeclarationList* QScript::AST::VariableDeclarationList::next

Definition at line 921 of file qscriptast_p.h.

Referenced by accept0(), finish(), and VariableDeclarationList().


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