Puma Reference Manual Puma: Puma::CT_ArrayDeclarator Class Reference



Puma::CT_ArrayDeclarator Class Reference

Tree node representing an array declarator. More...

#include <Puma/CTree.h>

Inheritance diagram for Puma::CT_ArrayDeclarator:
Inheritance graph

List of all members.

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.

Detailed Description

Tree node representing an array declarator.

Example:

 a[10] 

Constructor & Destructor Documentation

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

Constructor.

Parameters:
dThe array declarator.
oLeft bracket around the delimiter.
adThe array delimiter.
cRight bracket around the delimiter.

Member Function Documentation

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.

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.

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

Replace a son.

Parameters:
old_sonThe son to replace.
new_sonThe new son.

Reimplemented from Puma::CTree.

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

Get the semantic information object.

Reimplemented from Puma::CTree.

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

Get the n-th son.

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

Reimplemented from Puma::CTree.

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

Get the number of sons.

Implements 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.