Puma Reference Manual Puma: Puma::CT_ArrayDeclarator Class Reference



Puma::CT_ArrayDeclarator Class Reference

#include <Puma/CTree.h>

Inheritance diagram for Puma::CT_ArrayDeclarator:

Inheritance graph

List of all members.


Detailed Description

Tree node representing an array declarator.

Example:

 a[10] 

Public Member Functions

 CT_ArrayDeclarator (CTree *d, CTree *o, CTree *ad, CTree *c)
 Constructor.
const char * NodeName () const
 Get the name of the node.
int Sons () const
 Get the number of sons.
CTreeSon (int n) const
 Get the n-th son.
CTreeDeclarator () const
 Get the array declarator.
CT_ArrayDelimiterDelimiter () const
 Get the array delimiter.
void ReplaceSon (CTree *old_son, CTree *new_son)
 Replace a son.
CTypeInfoType () const
 Get the semantic information for the type of the declared array.
CExprValueValue () const
 Get the semantic information for the value of the declared array.
CSemValueSemValue () const
 Get the semantic information object.

Static Public Member Functions

static const char * NodeId ()
 Get the identifier for this node type.

Constructor & Destructor Documentation

Puma::CT_ArrayDeclarator::CT_ArrayDeclarator ( CTree d,
CTree o,
CTree ad,
CTree c 
) [inline]

Constructor.

Parameters:
d The array declarator.
o Left bracket around the delimiter.
ad The array delimiter.
c Right bracket around the delimiter.


Member Function Documentation

static const char* Puma::CT_ArrayDeclarator::NodeId (  )  [static]

Get the identifier for this node type.

Can be compared with NodeName().

const char* Puma::CT_ArrayDeclarator::NodeName (  )  const [inline, virtual]

Get the name of the node.

Can be compared with NodeId().

Implements Puma::CTree.

int Puma::CT_ArrayDeclarator::Sons (  )  const [inline, virtual]

Get the number of sons.

Implements Puma::CTree.

CTree* Puma::CT_ArrayDeclarator::Son ( int  n  )  const [inline, virtual]

Get the n-th son.

Parameters:
n The index of the son.
Returns:
The n-th son or NULL.

Reimplemented from Puma::CTree.

CTree* Puma::CT_ArrayDeclarator::Declarator (  )  const [inline, virtual]

Get the array declarator.

Implements Puma::CT_Declarator.

CT_ArrayDelimiter* Puma::CT_ArrayDeclarator::Delimiter (  )  const [inline]

Get the array delimiter.

void Puma::CT_ArrayDeclarator::ReplaceSon ( CTree old_son,
CTree new_son 
) [inline, virtual]

Replace a son.

Parameters:
old_son The son to replace.
new_son The new son.

Reimplemented from Puma::CTree.

CTypeInfo* Puma::CT_ArrayDeclarator::Type (  )  const [inline, virtual]

Get the semantic information for the type of the declared array.

Reimplemented from Puma::CTree.

CExprValue* Puma::CT_ArrayDeclarator::Value (  )  const [inline, virtual]

Get the semantic information for the value of the declared array.

Reimplemented from Puma::CTree.

CSemValue* Puma::CT_ArrayDeclarator::SemValue (  )  const [inline, virtual]

Get the semantic information object.

Reimplemented from Puma::CTree.




Puma Reference Manual. Created on 5 Nov 2008.