libabigail
|
The internal representation of an integral type. More...
#include <abg-ir-priv.h>
Public Types | |
enum | base_type { INT_BASE_TYPE , CHAR_BASE_TYPE , BOOL_BASE_TYPE , DOUBLE_BASE_TYPE , FLOAT_BASE_TYPE , CHAR16_T_BASE_TYPE , CHAR32_T_BASE_TYPE , WCHAR_T_BASE_TYPE , SIZE_BASE_TYPE , SSIZE_BASE_TYPE , BIT_SIZE_BASE_TYPE , SBIT_SIZE_BASE_TYPE , ARRAY_SIZE_BASE_TYPE } |
The possible base types of integral types. We might have forgotten many of these, so do not hesitate to add new ones. More... | |
enum | modifiers_type { NO_MODIFIER , SIGNED_MODIFIER , UNSIGNED_MODIFIER , SHORT_MODIFIER , LONG_MODIFIER , LONG_LONG_MODIFIER } |
The modifiers of the base types above. Several modifiers can be combined for a given base type. The presence of modifiers is usually modelled by a bitmap of modifiers. More... | |
Public Member Functions | |
real_type () | |
Default constructor of the real_type. | |
real_type (base_type, modifiers_type) | |
Constructor of the real_type. | |
real_type (const string &name) | |
Constructor of the real_type. | |
base_type | get_base_type () const |
Getter of the base type of the real_type. | |
modifiers_type | get_modifiers () const |
Getter of the modifiers bitmap of the real_type. | |
operator string () const | |
Convert the current instance of real_type into its string representation. | |
bool | operator== (const real_type &) const |
Equality operator for the real_type. | |
void | set_modifiers (modifiers_type) |
Setter of the modifiers bitmap of the real_type. | |
string | to_string (bool internal=false) const |
Return the string representation of the current instance of real_type. | |
The internal representation of an integral type.
This is a "utility type" used internally to canonicalize the name of fundamental integral types, so that "unsignd long" and "long unsined int" end-up having the same name.
Definition at line 47 of file abg-ir-priv.h.
enum base_type |
The possible base types of integral types. We might have forgotten many of these, so do not hesitate to add new ones.
If you do add new ones, please also consider updating functions parse_base_real_type and real_type::to_string.
Definition at line 55 of file abg-ir-priv.h.
enum modifiers_type |
The modifiers of the base types above. Several modifiers can be combined for a given base type. The presence of modifiers is usually modelled by a bitmap of modifiers.
If you add a new modifier, please consider updating functions parse_real_type_modifier and real_type::to_string.
Definition at line 87 of file abg-ir-priv.h.
real_type | ( | const string & | type_name | ) |
real_type | ( | base_type | b, |
modifiers_type | m ) |
real_type::base_type get_base_type | ( | ) | const |
real_type::modifiers_type get_modifiers | ( | ) | const |
operator string | ( | ) | const |
bool operator== | ( | const real_type & | other | ) | const |
void set_modifiers | ( | modifiers_type | m | ) |
string to_string | ( | bool | internal = false | ) | const |