CsTypeRef Struct Reference

Type AST node. More...

Inheritance diagram for CsTypeRef:
CsNode

List of all members.

Public Member Functions

 CsTypeRef ()
 CsTypeRef (LineInfo line_info)
virtual ~CsTypeRef ()
virtual void build_entities (CsDisplay &display)
 Build Entities - pass 2 (for internal purpose only).
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 clearEntities ()
 Clear all entity references (for internal purpose only).
virtual void visit (CsAstVisitor *visitor)
 CsAstVisitor support.
virtual void callback (CsAstCallback *visitor)
 CsAstCallback support.
virtual void addTokensRecursive (CsTokenCollector &tokenCollector)
 Recursively collect token indexes in source code order.
virtual void addTokens (CsTokenCollector &tokenCollector)
 Collect token indexes associated with this AST node.
virtual void addEntityDefinitions (CsEntityCollector &tokenCollector)
 Collect entities defined in this AST node.
virtual void addEntityReferences (CsEntityCollector &tokenCollector)
 Collect entity references.
bool isTypeName () const

Public Attributes

unsigned __int8 predefined_type
 Predefined type (CsTokenType).
bool nullable
 True if nullable type.
CsNodetype_name
 Type-name.
CsTypeSpecifiersspecifiers
 Type specifiers.
CsEntityTypeRef entity_typeref
 Entity type reference.
CsTokenIndex separator_token
CsTokenIndex predefined_type_token
CsTokenIndex question_token
CsUsingAliasDirectiveusing_directive_used_in_type_lookup

Detailed Description

Type AST node.

EBNF grammar:

type:
  type-name
  "bool"
  "byte"
  "char"
  "decimal"
  "double"
  "float"
  "int"
  "long"
  "object"
  "sbyte"
  "string"
  "short"
  "uint"
  "ulong"
  "ushort"
  non-array-type rank-specifiers
  pointer-type

pointer-type:
  unmanaged-type "*"
  void "*"

unmanaged-type:
  type

rank-specifiers:
  ( rank-specifier )+

rank-specifier:
  "[" ( "," )* "]"


Constructor & Destructor Documentation

CsTypeRef::CsTypeRef (  )  [inline]
CsTypeRef::CsTypeRef ( LineInfo  line_info  )  [inline, explicit]
virtual CsTypeRef::~CsTypeRef (  )  [inline, virtual]

Member Function Documentation

virtual void CsTypeRef::addEntityDefinitions ( CsEntityCollector tokenCollector  )  [inline, virtual]

Collect entities defined in this AST node.

Implements CsNode.

virtual void CsTypeRef::addEntityReferences ( CsEntityCollector tokenCollector  )  [inline, virtual]

Collect entity references.

Implements CsNode.

virtual void CsTypeRef::addTokens ( CsTokenCollector tokenCollector  )  [virtual]

Collect token indexes associated with this AST node.

Implements CsNode.

virtual void CsTypeRef::addTokensRecursive ( CsTokenCollector tokenCollector  )  [virtual]

Recursively collect token indexes in source code order.

Implements CsNode.

virtual void CsTypeRef::build_entities ( CsDisplay &  display  )  [inline, virtual]

Build Entities - pass 2 (for internal purpose only).

Implements CsNode.

virtual void CsTypeRef::callback ( CsAstCallback visitor  )  [inline, virtual]

CsAstCallback support.

Implements CsNode.

virtual void CsTypeRef::clearEntities (  )  [virtual]

Clear all entity references (for internal purpose only).

Implements CsNode.

bool CsTypeRef::isTypeName (  )  const [inline]
virtual void CsTypeRef::member_lookup ( CsDisplay &  display  )  [inline, virtual]

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

Implements CsNode.

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

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

Implements CsNode.

virtual void CsTypeRef::visit ( CsAstVisitor visitor  )  [inline, virtual]

CsAstVisitor support.

Implements CsNode.


Member Data Documentation

True if nullable type.

unsigned __int8 CsTypeRef::predefined_type

Predefined type (CsTokenType).

tkEOF - if type is a type-name,
or one of: tkBOOL, tkBYTE, tkCHAR, tkDECIMAL, tkDOUBLE, tkFLOAT, tkINT, tkLONG, tkOBJECT, tkSBYTE, tkSHORT, tkSTRING, tkUINT, tkULONG, tkUSHORT, tkVOID.

Using-directive which was used in type lookup.


This field was introduced for rename refactoring support.

© 2010 metaspec