#include <JumpInstruction.h>
Inheritance diagram for JumpInstructionRegister:
Static Public Member Functions | |
static void | registerInstructions () |
Static Private Member Functions | |
template<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 263 of file JumpInstruction.h.
static void JumpInstructionRegister::registerTypes | ( | vector< StandardTypeDescriptorOrdinal > const & | t | ) | [inline, static, private] |
Definition at line 269 of file JumpInstruction.h.
00269 { 00270 00271 for (uint i = 0; i < t.size(); i++) { 00272 StandardTypeDescriptorOrdinal type = t[i]; 00273 InstructionSignature sig = INSTCLASS2::signature(type); 00274 switch (type) { 00275 #define Fennel_InstructionRegisterSwitch_Bool 1 00276 #include "fennel/calculator/InstructionRegisterSwitch.h" 00277 default: 00278 throw std::logic_error("Default InstructionRegister"); 00279 } 00280 } 00281 }
static void JumpInstructionRegister::registerInstructions | ( | ) | [inline, static] |
Definition at line 285 of file JumpInstruction.h.
References STANDARD_TYPE_BOOL.
Referenced by InstructionFactory::registerInstructions().
00285 { 00286 vector<StandardTypeDescriptorOrdinal> t; 00287 t.push_back(STANDARD_TYPE_BOOL); 00288 00289 // Have to do full fennel:: qualification of template 00290 // arguments below to prevent template argument 'TMPLT', of 00291 // this encapsulating class, from perverting NativeAdd into 00292 // NativeAdd<TMPLT> or something like 00293 // that. Anyway. Fennel::NativeAdd works just fine. 00294 registerTypes<fennel::Jump>(t); 00295 registerTypes<fennel::JumpTrue>(t); 00296 registerTypes<fennel::JumpFalse>(t); 00297 registerTypes<fennel::JumpNull>(t); 00298 registerTypes<fennel::JumpNotNull>(t); 00299 }
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 }