#include <PointerPointerInstruction.h>
Inheritance diagram for PointerPointerInstructionRegister:
Static Public Member Functions | |
static void | registerInstructions () |
Static Private Member Functions | |
template<template< typename > class INSTCLASS2> | |
static void | registerTypes (vector< StandardTypeDescriptorOrdinal > const &t) |
template<typename TYPE1, template< typename > class INSTCLASS> | |
static void | registerInstance (StandardTypeDescriptorOrdinal type) |
template<typename IGNOREDDATATYPE, class INSTCLASS> | |
static void | registerInstance (StandardTypeDescriptorOrdinal type) |
template<typename TYPE1, typename TYPE2, template< typename, typename > class INSTCLASS> | |
static void | registerInstance2 (StandardTypeDescriptorOrdinal type1, StandardTypeDescriptorOrdinal type2) |
Definition at line 494 of file PointerPointerInstruction.h.
static void PointerPointerInstructionRegister::registerTypes | ( | vector< StandardTypeDescriptorOrdinal > const & | t | ) | [inline, static, private] |
Definition at line 500 of file PointerPointerInstruction.h.
00500 { 00501 00502 for (uint i = 0; i < t.size(); i++) { 00503 StandardTypeDescriptorOrdinal type = t[i]; 00504 // Type <char> below is a placeholder and is ignored. 00505 InstructionSignature sig = INSTCLASS2<char>::signature(type); 00506 switch (type) { 00507 // Array_Text, below, does not allow assembly programs 00508 // of to have say, pointer to int16s, but the language 00509 // does not have pointers defined other than 00510 // c,vc,b,vb, so this is OK for now. 00511 #define Fennel_InstructionRegisterSwitch_Array 1 00512 #include "fennel/calculator/InstructionRegisterSwitch.h" 00513 default: 00514 throw std::logic_error("Default InstructionRegister"); 00515 } 00516 } 00517 }
static void PointerPointerInstructionRegister::registerInstructions | ( | ) | [inline, static] |
Definition at line 521 of file PointerPointerInstruction.h.
References StandardTypeDescriptor::isArray(), and InstructionSignature::typeVector().
Referenced by InstructionFactory::registerInstructions().
00521 { 00522 vector<StandardTypeDescriptorOrdinal> t; 00523 // isArray, below, does not allow assembly programs of to 00524 // have say, pointer to int16s, but the language does not have 00525 // pointers defined other than c,vc,b,vb, so this is OK for now. 00526 t = InstructionSignature::typeVector(StandardTypeDescriptor::isArray); 00527 00528 // Have to do full fennel:: qualification of template 00529 // arguments below to prevent template argument 'TMPLT', of 00530 // this encapsulating class, from perverting NativeAdd into 00531 // NativeAdd<TMPLT> or something like 00532 // that. Anyway. Fennel::NativeAdd works just fine. 00533 registerTypes<fennel::PointerAdd>(t); 00534 registerTypes<fennel::PointerSub>(t); 00535 registerTypes<fennel::PointerMove>(t); 00536 registerTypes<fennel::PointerRef>(t); 00537 registerTypes<fennel::PointerToNull>(t); 00538 }
static void InstructionRegister::registerInstance | ( | StandardTypeDescriptorOrdinal | type | ) | [inline, static, protected, inherited] |
Definition at line 139 of file Instruction.h.
References InstructionFactory::getInstructionTable().
Referenced by ReturnInstructionRegister::registerInstructions().
00140 { 00141 StringToCreateFn* instMap = InstructionFactory::getInstructionTable(); 00142 (*instMap)[INSTCLASS<TYPE1>::signature(type).compute()] = 00143 &INSTCLASS<TYPE1>::create; 00144 }
static void InstructionRegister::registerInstance | ( | StandardTypeDescriptorOrdinal | type | ) | [inline, static, protected, inherited] |
Definition at line 161 of file Instruction.h.
References InstructionFactory::getInstructionTable().
00162 { 00163 StringToCreateFn* instMap = InstructionFactory::getInstructionTable(); 00164 (*instMap)[INSTCLASS::signature(type).compute()] = 00165 &INSTCLASS::create; 00166 }
static void InstructionRegister::registerInstance2 | ( | StandardTypeDescriptorOrdinal | type1, | |
StandardTypeDescriptorOrdinal | type2 | |||
) | [inline, static, protected, inherited] |
Definition at line 150 of file Instruction.h.
References InstructionFactory::getInstructionTable().
00153 { 00154 StringToCreateFn* instMap = InstructionFactory::getInstructionTable(); 00155 (*instMap)[INSTCLASS<TYPE1,TYPE2>::signature(type1, type2).compute()] = 00156 &INSTCLASS<TYPE1,TYPE2>::create; 00157 }