7 #ifndef RETDEC_LLVMIR2HLL_IR_INT_TYPE_H
8 #define RETDEC_LLVMIR2HLL_IR_INT_TYPE_H
A representation of an integer type.
Definition: int_type.h:26
unsigned size
Number of bits (size of the integer).
Definition: int_type.h:49
bool isBool() const
Returns true if the type is bool, false otherwise.
Definition: int_type.cpp:64
static SizeToIntTypeMap createdUnsignedTypes
Set of already created unsigned integer types of the given size.
Definition: int_type.h:58
bool signedInt
Is the integer signed?
Definition: int_type.h:52
unsigned getSize() const
Returns the number of bits.
Definition: int_type.cpp:37
virtual void accept(Visitor *v) override
Visitor pattern implementation.
Definition: int_type.cpp:104
bool isSigned() const
Returns true if the integer is signed, false otherwise.
Definition: int_type.cpp:46
bool isUnsigned() const
Returns true if the integer is unsigned, false otherwise.
Definition: int_type.cpp:55
static ShPtr< IntType > create(unsigned size, bool isSigned=true)
Creates a new integer type.
Definition: int_type.cpp:78
IntType(unsigned size, bool isSigned=false)
Constructs a new integer type.
Definition: int_type.cpp:19
virtual bool isEqualTo(ShPtr< Value > otherValue) const override
Returns true if this value is equal to otherValue, false otherwise.
Definition: int_type.cpp:26
static SizeToIntTypeMap createdSignedTypes
Set of already created signed integer types of the given size.
Definition: int_type.h:55
virtual ShPtr< Value > clone() override
Returns a clone of the value.
Definition: int_type.cpp:22
std::map< unsigned, ShPtr< IntType > > SizeToIntTypeMap
Mapping of integer sizes into IntType instances.
Definition: int_type.h:45
A base class of all types.
Definition: type.h:20
A base class of all visitors.
Definition: visitor.h:95
A base class of all types.
A library providing API for working with back-end IR.
std::shared_ptr< T > ShPtr
An alias for a shared pointer.
Definition: smart_ptr.h:18
Definition: archive_wrapper.h:19
Declarations, aliases, macros, etc. for the use of smart pointers.