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

#include <qdeclarativejsast_p.h>

Inheritance diagram for QDeclarativeJS::AST::VariableDeclarationList:
QDeclarativeJS::AST::Node

Public Functions

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

Public Variables

SourceLocation commaToken
 
VariableDeclarationdeclaration
 
VariableDeclarationListnext
 
- Public Variables inherited from QDeclarativeJS::AST::Node
int kind
 

Additional Inherited Members

- Public Types inherited from QDeclarativeJS::AST::Node
enum  Kind {
  Kind_Undefined, Kind_ArgumentList, Kind_ArrayLiteral, Kind_ArrayMemberExpression,
  Kind_BinaryExpression, Kind_Block, Kind_BreakStatement, Kind_CallExpression,
  Kind_CaseBlock, Kind_CaseClause, Kind_CaseClauses, Kind_Catch,
  Kind_ConditionalExpression, Kind_ContinueStatement, Kind_DebuggerStatement, Kind_DefaultClause,
  Kind_DeleteExpression, Kind_DoWhileStatement, Kind_ElementList, Kind_Elision,
  Kind_EmptyStatement, Kind_Expression, Kind_ExpressionStatement, Kind_FalseLiteral,
  Kind_FieldMemberExpression, Kind_Finally, Kind_ForEachStatement, Kind_ForStatement,
  Kind_FormalParameterList, Kind_FunctionBody, Kind_FunctionDeclaration, Kind_FunctionExpression,
  Kind_FunctionSourceElement, Kind_IdentifierExpression, Kind_IdentifierPropertyName, Kind_IfStatement,
  Kind_LabelledStatement, Kind_LocalForEachStatement, Kind_LocalForStatement, Kind_NewExpression,
  Kind_NewMemberExpression, Kind_NotExpression, Kind_NullExpression, Kind_NumericLiteral,
  Kind_NumericLiteralPropertyName, Kind_ObjectLiteral, Kind_PostDecrementExpression, Kind_PostIncrementExpression,
  Kind_PreDecrementExpression, Kind_PreIncrementExpression, Kind_Program, Kind_PropertyName,
  Kind_PropertyNameAndValueList, Kind_RegExpLiteral, Kind_ReturnStatement, Kind_SourceElement,
  Kind_SourceElements, Kind_StatementList, Kind_StatementSourceElement, Kind_StringLiteral,
  Kind_StringLiteralPropertyName, Kind_SwitchStatement, Kind_ThisExpression, Kind_ThrowStatement,
  Kind_TildeExpression, Kind_TrueLiteral, Kind_TryStatement, Kind_TypeOfExpression,
  Kind_UnaryMinusExpression, Kind_UnaryPlusExpression, Kind_VariableDeclaration, Kind_VariableDeclarationList,
  Kind_VariableStatement, Kind_VoidExpression, Kind_WhileStatement, Kind_WithStatement,
  Kind_NestedExpression, Kind_UiArrayBinding, Kind_UiImport, Kind_UiImportList,
  Kind_UiObjectBinding, Kind_UiObjectDefinition, Kind_UiObjectInitializer, Kind_UiObjectMemberList,
  Kind_UiArrayMemberList, Kind_UiProgram, Kind_UiParameterList, Kind_UiPublicMember,
  Kind_UiQualifiedId, Kind_UiScriptBinding, Kind_UiSourceElement, Kind_UiFormal,
  Kind_UiFormalList, Kind_UiSignature
}
 
- Static Public Functions inherited from QDeclarativeJS::AST::Node
static void accept (Node *node, Visitor *visitor)
 
static void acceptChild (Node *node, Visitor *visitor)
 

Detailed Description

Definition at line 1293 of file qdeclarativejsast_p.h.

Constructors and Destructors

◆ VariableDeclarationList() [1/2]

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

Definition at line 1298 of file qdeclarativejsast_p.h.

1298  :
1299  declaration (decl), next (this)
1300  { kind = K; }

◆ VariableDeclarationList() [2/2]

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

Definition at line 1302 of file qdeclarativejsast_p.h.

1302  :
1303  declaration (decl)
1304  {
1305  kind = K;
1306  next = previous->next;
1307  previous->next = this;
1308  }

Functions

◆ accept0()

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

Implements QDeclarativeJS::AST::Node.

Definition at line 470 of file qdeclarativejsast.cpp.

471 {
472  if (visitor->visit(this)) {
473  for (VariableDeclarationList *it = this; it; it = it->next) {
474  accept(it->declaration, visitor);
475  }
476  }
477 
478  visitor->endVisit(this);
479 }
#define it(className, varName)
void accept(Visitor *visitor)

◆ finish()

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

Definition at line 1312 of file qdeclarativejsast_p.h.

Referenced by QDeclarativeJS::Parser::parse().

1313  {
1314  VariableDeclarationList *front = next;
1315  next = 0;
1316  if (readOnly) {
1318  for (vdl = front; vdl != 0; vdl = vdl->next)
1319  vdl->declaration->readOnly = true;
1320  }
1321  return front;
1322  }

Properties

◆ commaToken

SourceLocation QDeclarativeJS::AST::VariableDeclarationList::commaToken

Definition at line 1327 of file qdeclarativejsast_p.h.

Referenced by QDeclarativeJS::Parser::parse().

◆ declaration

VariableDeclaration* QDeclarativeJS::AST::VariableDeclarationList::declaration

Definition at line 1325 of file qdeclarativejsast_p.h.

Referenced by finish().

◆ next

VariableDeclarationList* QDeclarativeJS::AST::VariableDeclarationList::next

Definition at line 1326 of file qdeclarativejsast_p.h.

Referenced by finish(), and VariableDeclarationList().


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