retdec
|
A representation of L-Value and R-Value reference types. More...
#include <reference_type.h>
Public Member Functions | |
std::shared_ptr< Type > | getReferencedType () const |
Returns referencedType. More... | |
bool | isReference () const override |
Visitor interface. | |
virtual void | accept (Visitor *v) override |
Visitor pattern implementation. More... | |
![]() | |
virtual | ~Type ()=default |
const std::string & | getName () const |
unsigned | getBitWidth () const |
virtual bool | isArray () const |
virtual bool | isEnum () const |
virtual bool | isFloatingPoint () const |
virtual bool | isFunction () const |
virtual bool | isIntegral () const |
virtual bool | isNamed () const |
virtual bool | isPointer () const |
virtual bool | isStruct () const |
virtual bool | isTypedef () const |
virtual bool | isUnion () const |
virtual bool | isUnknown () const |
virtual bool | isVoid () const |
Static Public Member Functions | |
static std::shared_ptr< ReferenceType > | create (const std::shared_ptr< Context > &context, const std::shared_ptr< Type > &referencedType, unsigned bitWidth=0) |
Private Member Functions | |
ReferenceType (const std::shared_ptr< Type > &referencedType, unsigned bitWidth=0) | |
Constructs new reference type. More... | |
Private Attributes | |
std::shared_ptr< Type > | referencedType |
Additional Inherited Members | |
![]() | |
Type ()=default | |
Type (const std::string &name, unsigned bitWidth) | |
Constructs a new type. More... | |
![]() | |
Visitable ()=default | |
~Visitable ()=default | |
![]() | |
std::string | name |
unsigned | bitWidth |
A representation of L-Value and R-Value reference types.
|
explicitprivate |
Constructs new reference type.
|
overridevirtual |
Visitor pattern implementation.
Subclasses should implement this method as:
where T
is the name of the subclass.
Implements retdec::ctypes::Visitable.
|
static |
Creates reference type.
context | Storage for already created functions, types. |
referencedType | Type that reference references. |
bitWidth | Number of bits used by this type. |
Does not create new pointer type, if one has already been created and stored in context
.
std::shared_ptr< Type > retdec::ctypes::ReferenceType::getReferencedType | ( | ) | const |
Returns referencedType.
|
overridevirtual |
Returns true
when Type is pointer, false
otherwise.
Reimplemented from retdec::ctypes::Type.
|
private |