diff --git a/include/builtin.h b/include/builtin.h index 5e42a47..05a60e8 100644 --- a/include/builtin.h +++ b/include/builtin.h @@ -7,14 +7,3 @@ ObjectBase* Arifm_Div(const ObjectList* input); ObjectBase* Arifm_Pow(const ObjectList* input); ObjectBase* Arifm_Neg(const ObjectList* input); ObjectBase* Arifm_Pos(const ObjectList* input); - -template -ObjectBase* Get(const ObjectList* input) -{ - if(input->Size()!=2) return 0; - OBType ob(input->At(0)); - OBType name(input->At(1)); - if(!(ob && name)) return 0; - - return ob->Get(name->Value()); -} diff --git a/include/common.h b/include/common.h index 520096d..77b74f9 100644 --- a/include/common.h +++ b/include/common.h @@ -278,4 +278,15 @@ EXPORT void RegisterFunction(const std::string& name, Func func); EXPORT int LoadModule(const std::string& name, const void* p, const std::string& modname=""); } -#endif \ No newline at end of file +template +ObjectBase* Get(const ObjectList* input) +{ + if(input->Size()!=2) return 0; + OBType ob(input->At(0)); + OBType name(input->At(1)); + if(!(ob && name)) return 0; + + return ob->Get(name->Value()); +} + +#endif