Zen
A cross-platform functional programming language

QualifiedType Class Reference

A type with const and ref qualifiers. More...

#include <Ast.hpp>

Inheritance diagram for QualifiedType:
Node

List of all members.

Public Types

typedef z::list< const
QualifiedType * > 
List
 Default list of QualifiedType nodes To be used wherever required by any of the other nodes.

Public Member Functions

 QualifiedType (const bool &isConst, const TypeSpec &type, const bool &isRef)
 Constructor for QualifiedType.
const bool & isConst () const
 Returns whether this is a const type specifier.
const bool & isRef () const
 Returns whether this is a ref type specifier.
const TypeSpecgetTypeSpec () const
 Returns the type specifier.

Private Attributes

bool _isConst
 Whether this is a const type.
const TypeSpec_type
 The TypeSpec being qualified.
bool _isRef
 Whether this is a reference type.

Detailed Description

A type with const and ref qualifiers.

This class represents a TypeSpec along with its qualifiers. For example, if 'int' is a type, 'const int&' will be the type qualified with const and ref.


Constructor & Destructor Documentation

QualifiedType ( const bool &  isConst,
const TypeSpec type,
const bool &  isRef 
) [inline]

Constructor for QualifiedType.

Parameters:
isConstSpecifies whether this QualifiedType has a const qualifier
typeThe typespec of this QualifiedType
isRefSpecifies whether this QualifiedType has a ref qualifier

Member Function Documentation

const TypeSpec& getTypeSpec ( ) const [inline]

Returns the type specifier.

Returns:
The TypeSpec being qualified
const bool& isConst ( ) const [inline]

Returns whether this is a const type specifier.

Returns:
The const value
const bool& isRef ( ) const [inline]

Returns whether this is a ref type specifier.

Returns:
The ref value

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