#include <ArrayType.hpp>
Public Types | |
enum | LengthSpec { NOT_SPECIFIED, FIXED, VARIABLE, VARIABLE_NOT_SPECIFIED, INCOMPLETE } |
Public Member Functions | |
ArrayType (const Type *baseType, QualFlags qualFlags, LengthSpec lengthSpec) | |
ArrayType (const Type *baseType, ConstantValue &lengthValue, QualFlags qualFlags) | |
ArrayType (const ArrayType &other) | |
virtual | ~ArrayType () |
virtual ArrayType * | clone () const |
virtual bool | isCompatibleType (const Type *other) const |
virtual size_t | getSize (const TargetInfo &targetInfo) const |
virtual size_t | getAlign (const TargetInfo &targetInfo) const |
const Type * | getBaseType () const |
const ConstantValue & | getLengthValue () const |
QualFlags | getQualFlags () const |
LengthSpec | getLengthSpec () const |
void | setBaseType (const Type *t) |
void | setLengthValue (const ConstantValue lengthValue) |
Protected Attributes | |
const Type * | baseType_ |
ConstantValue | lengthValue_ |
QualFlags | qualFlags_ |
LengthSpec | lengthSpec_ |
Definition at line 42 of file ArrayType.hpp.
Constants represents the types of the length of the array.
Definition at line 48 of file ArrayType.hpp.
cfront::ArrayType::ArrayType | ( | const Type * | baseType, | |
QualFlags | qualFlags, | |||
LengthSpec | lengthSpec | |||
) | [inline] |
cfront::ArrayType::ArrayType | ( | const Type * | baseType, | |
ConstantValue & | lengthValue, | |||
QualFlags | qualFlags | |||
) | [inline] |
Definition at line 60 of file ArrayType.hpp.
cfront::ArrayType::ArrayType | ( | const ArrayType & | other | ) | [inline] |
Definition at line 64 of file ArrayType.hpp.
virtual cfront::ArrayType::~ArrayType | ( | ) | [inline, virtual] |
Definition at line 69 of file ArrayType.hpp.
virtual ArrayType* cfront::ArrayType::clone | ( | ) | const [inline, virtual] |
Return the copy of self.
Implements cfront::Type.
Definition at line 71 of file ArrayType.hpp.
References ArrayType().
virtual bool cfront::ArrayType::isCompatibleType | ( | const Type * | other | ) | const [inline, virtual] |
Tests whether this type is compatible to the given one.
Implements cfront::Type.
Definition at line 76 of file ArrayType.hpp.
References baseType_, and cfront::Type::isCompatibleType().
virtual size_t cfront::ArrayType::getSize | ( | const TargetInfo & | targetInfo | ) | const [inline, virtual] |
Implements cfront::Type.
Definition at line 83 of file ArrayType.hpp.
References getBaseType(), getLengthValue(), and cfront::Type::getSize().
virtual size_t cfront::ArrayType::getAlign | ( | const TargetInfo & | targetInfo | ) | const [inline, virtual] |
Implements cfront::Type.
Definition at line 89 of file ArrayType.hpp.
References cfront::Type::getAlign(), and getBaseType().
const Type* cfront::ArrayType::getBaseType | ( | ) | const [inline] |
Definition at line 94 of file ArrayType.hpp.
References baseType_.
Referenced by cfront::CAnalyzer::convertUnaryExprType(), getAlign(), cfront::CAnalyzer::getInitializerListElemType(), cfront::CAnalyzer::getOriginalType(), and getSize().
const ConstantValue& cfront::ArrayType::getLengthValue | ( | ) | const [inline] |
Definition at line 99 of file ArrayType.hpp.
References lengthValue_.
Referenced by cfront::CAnalyzer::checkArrayInitializer(), and getSize().
QualFlags cfront::ArrayType::getQualFlags | ( | ) | const [inline] |
Definition at line 104 of file ArrayType.hpp.
References qualFlags_.
Referenced by cfront::CAnalyzer::convertUnaryExprType().
LengthSpec cfront::ArrayType::getLengthSpec | ( | ) | const [inline] |
Definition at line 109 of file ArrayType.hpp.
References lengthSpec_.
Referenced by cfront::CAnalyzer::checkArrayInitializer().
void cfront::ArrayType::setBaseType | ( | const Type * | t | ) | [inline] |
Definition at line 114 of file ArrayType.hpp.
References baseType_.
Referenced by cfront::CAnalyzer::buildCompositeDeclaratorType(), and cfront::CAnalyzer::buildDeclaratorPostfixType().
void cfront::ArrayType::setLengthValue | ( | const ConstantValue | lengthValue | ) | [inline] |
Definition at line 119 of file ArrayType.hpp.
References lengthValue_.
Referenced by cfront::CAnalyzer::checkArrayInitializer().
const Type* cfront::ArrayType::baseType_ [protected] |
Definition at line 135 of file ArrayType.hpp.
Referenced by getBaseType(), isCompatibleType(), and setBaseType().
ConstantValue cfront::ArrayType::lengthValue_ [protected] |
QualFlags cfront::ArrayType::qualFlags_ [protected] |
LengthSpec cfront::ArrayType::lengthSpec_ [protected] |