Привет, у меня проблема с компиляцией моего класса в XCode, gcc (Apple LLVM compiler 3.0)
Я написал класс ContextSchedule, то есть класс, который инкапсулирует список других функций-членов класса и не имеет проблем с его компиляцией под MSVC ++ 2005.
template<class T>
class C_ContextScheduler
{
public:
typedef void (T::*T_EventFunc)();
typedef std::map<u64, T_EventFunc> T_EventMap;
public:
//@ c-tor
C_ContextScheduler(T & context) : m_Context(context), m_currentTick(0) {};
//@ Schedule
//@ funcPtr - pointer to function of class T
//@ dellayTime in milliseconds - after dellayTime from now will be funcPtr called
void Schedule(T_EventFunc funcPtr, u32 dellayTime)
{
u64 callingTime = m_currentTick + dellayTime;
std::pair<int, bool> res = m_eventMap.insert(T_EventMap::value_type(callingTime, funcPtr));
SC_ASSERT(res.second);
} ...
Есть идеи? Хочу сохранить шаблонный способ решения, thnx.