top | up | prev | next

PointerPlusOffset Class

Definition at line 493 of OperationRepository.cpp

Constructors

PointerPlusOffset(TypeSymbol* pointerType_, TypeSymbol* longType_, const Span& span, const boost::uuids::uuid& moduleId)

Member Functions

const char* ClassName() const override
SymbolAccess DeclaredAccess() const override
void GenerateCall(Emitter& emitter, std::vector<GenObject*>& genObjects, OperationFlags flags, const Span& span, const boost::uuids::uuid& moduleId) override
bool IsBasicTypeOperation() const override

Constructor Details

PointerPlusOffset Constructor

cmajor::binder::PointerPlusOffset::PointerPlusOffset(TypeSymbol* pointerType_, TypeSymbol* longType_, const Span& span, const boost::uuids::uuid& moduleId)

Definition at line 503 of OperationRepository.cpp
Declaration at line 496 of OperationRepository.cpp


Member Function Details

ClassName Member Function

const char * cmajor::binder::PointerPlusOffset::ClassName() const override

Definition at line 500 of OperationRepository.cpp :
 500 { return "PointerPlusOffset"; }


DeclaredAccess Member Function

SymbolAccess cmajor::binder::PointerPlusOffset::DeclaredAccess() const override

Definition at line 497 of OperationRepository.cpp :
 497 { return SymbolAccess::public_; }


GenerateCall Member Function

void cmajor::binder::PointerPlusOffset::GenerateCall(Emitter& emitter, std::vector<GenObject*>& genObjects, OperationFlags flags, const Span& span, const boost::uuids::uuid& moduleId) override

Definition at line 517 of OperationRepository.cpp :
 518 {
 519     Assert(genObjects.size() == 2"operator+ needs two objects");
 520     genObjects[0]->Load(emitterOperationFlags::none);
 521     void* left = emitter.Stack().Pop();
 522     genObjects[1]->Load(emitterOperationFlags::none);
 523     void* right = emitter.Stack().Pop();
 524     emitter.Stack().Push(emitter.ComputeAddress(leftright));
 525 }


Declaration at line 498 of OperationRepository.cpp


IsBasicTypeOperation Member Function

bool cmajor::binder::PointerPlusOffset::IsBasicTypeOperation() const override

Definition at line 499 of OperationRepository.cpp :
 499 { return true; }


top | up | prev | next