Zen
A cross-platform functional programming language

VariableRef Class Reference

Node containg reference to variables. More...

#include <Ast.hpp>

Inheritance diagram for VariableRef:
VariableDefListBase Node

List of all members.

Public Member Functions

 VariableRef (const Storage::T &storage)
 Default constructor.
const Ast::QualifiedTypegetType () const
 Returns the qualified type of the variable being referenced.
const z::stringgetName () const
 Returns the name of the variable being referenced.
void setStorage (const Storage::T &storage)
 Sets the storage type of the variable being referenced.
const Storage::TgetStorage () const
 Returns the storage type of the variable being referenced.

Private Attributes

Storage::T _storage
 The storage type of the variable being referenced.

Detailed Description

Node containg reference to variables.

This node is used in an expression to hold a reference to a variable. This is implemented as a list of VariableDef pointers, since a reference can be, for example local x = a.b.c; In this case, the VariableRef instance will hold a list of [a,b,c]


Constructor & Destructor Documentation

VariableRef ( const Storage::T storage) [inline]

Default constructor.

Parameters:
storageThe storage type of the variable being referenced.

Member Function Documentation

const z::string& getName ( ) const [inline]

Returns the name of the variable being referenced.

Returns:
The name of the variable being referenced.
const Storage::T& getStorage ( ) const [inline]

Returns the storage type of the variable being referenced.

Returns:
The storage type of the variable being referenced.
const Ast::QualifiedType& getType ( ) const [inline]

Returns the qualified type of the variable being referenced.

Returns:
The qualified type of the variable being referenced.

The documentation for this class was generated from the following file:
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Defines