CsLiteral Struct Reference

Literal expression AST node. More...

Inheritance diagram for CsLiteral:

CsPrimaryExpression CsExpression CsNode List of all members.

Public Member Functions

 CsLiteral ()
 CsLiteral (LineInfo line_info)
virtual ~CsLiteral ()
virtual void type_lookup (CsDisplay &display)
 Type Lookup - pass 3 (for internal purpose only).
virtual void member_lookup (CsDisplay &display)
 Member Lookup - pass 4 (for internal purpose only).
virtual void addTokensRecursive (CsTokenCollector &tokenCollector)
 Recusively collect token indexes in source code order.
virtual void addTokens (CsTokenCollector &tokenCollector)
 Collect token indexes associated with this AST node.

Public Attributes

CsTokenType type
 Literal token type (one of: tkTRUE, tkFALSE, tkNULL or tkLITERAL).
PHashString string
 Literal string representation (for literal only).
CsLiteralType literal_type
 Literal type (for literals only).
unsigned __int64 value
 Literal value (for integral literals only).
CsTokenIndex literal_token

Detailed Description

Literal expression AST node.

EBNF grammar:

literal:
  true
  false
  null
  literal-token


Constructor & Destructor Documentation

CsLiteral::CsLiteral  )  [inline]
 

CsLiteral::CsLiteral LineInfo  line_info  )  [inline, explicit]
 

virtual CsLiteral::~CsLiteral  )  [inline, virtual]
 


Member Function Documentation

virtual void CsLiteral::addTokens CsTokenCollector tokenCollector  )  [virtual]
 

Collect token indexes associated with this AST node.

Implements CsNode.

virtual void CsLiteral::addTokensRecursive CsTokenCollector tokenCollector  )  [virtual]
 

Recusively collect token indexes in source code order.

Implements CsNode.

virtual void CsLiteral::member_lookup CsDisplay &  display  )  [virtual]
 

Member Lookup - pass 4 (for internal purpose only).

Implements CsNode.

virtual void CsLiteral::type_lookup CsDisplay &  display  )  [inline, virtual]
 

Type Lookup - pass 3 (for internal purpose only).

Implements CsNode.


Member Data Documentation

CsTokenIndex CsLiteral::literal_token
 

CsLiteralType CsLiteral::literal_type
 

Literal type (for literals only).

PHashString CsLiteral::string
 

Literal string representation (for literal only).

CsTokenType CsLiteral::type
 

Literal token type (one of: tkTRUE, tkFALSE, tkNULL or tkLITERAL).

Reimplemented from CsNode.

unsigned __int64 CsLiteral::value
 

Literal value (for integral literals only).

© 2005 metaspec