AALanguage
The best language for those who have nothing to do
|
A class to represent an expression type. More...
#include <TableIdentifiers.h>
Public Member Functions | |
Type (ExprType expr_type_, bool is_const_, bool is_array_, int array_size_=-1) | |
A constructor that specifies the public fields of the type. | |
Type () | |
Default Constructor. | |
bool | operator== (const Type &other) const |
Type comparison operator. | |
bool | operator!= (const Type &other) const |
Type comparison operator (not equality). | |
Public Attributes | |
ExprType | expr_type |
Standard expression type. | |
bool | is_const |
Whether the expression is constant (in case it is a variable) | |
bool | is_array |
Whether the expression is an array. | |
int | array_size |
The size of the array or -1 if the type is not an array. | |
A class to represent an expression type.
Definition at line 28 of file TableIdentifiers.h.
|
inline |
A constructor that specifies the public fields of the type.
Definition at line 40 of file TableIdentifiers.h.
References array_size, expr_type, is_array, and is_const.
|
inline |
Default Constructor.
Sets:
Definition at line 54 of file TableIdentifiers.h.
References array_size, expr_type, is_array, is_const, and Unknown.
|
inline |
Type comparison operator (not equality).
Compares all public attributes.
other | Another type to compare. |
Definition at line 76 of file TableIdentifiers.h.
|
inline |
Type comparison operator.
Compares all public attributes.
other | Another type to compare. |
Definition at line 66 of file TableIdentifiers.h.
References array_size, expr_type, is_array, and is_const.
int Type::array_size |
The size of the array or -1 if the type is not an array.
Definition at line 36 of file TableIdentifiers.h.
Referenced by Analyzer::function(), Semantic::is_convertible(), operator==(), Type(), Type(), and Semantic::type_to_string().
ExprType Type::expr_type |
Standard expression type.
Definition at line 30 of file TableIdentifiers.h.
Referenced by Poliz::address_to_value(), Semantic::calc_expr_type(), Semantic::check_operation(), Poliz::copy_value(), Poliz::execute(), Analyzer::field(), Analyzer::function(), Semantic::is_convertible(), operator==(), Analyzer::switch_statement(), Type(), Type(), and Semantic::type_to_string().
bool Type::is_array |
Whether the expression is an array.
Definition at line 34 of file TableIdentifiers.h.
Referenced by Analyzer::field(), Analyzer::function(), Semantic::is_convertible(), operator==(), Type(), Type(), and Semantic::type_to_string().
bool Type::is_const |
Whether the expression is constant (in case it is a variable)
Definition at line 32 of file TableIdentifiers.h.
Referenced by operator==(), Type(), and Type().