Why am I getting a Linker error with template function pointer?
I have a class EventMgr which has a template function to register a listener. But, when I register a listener, linker gives me a " error LNK2019: unresolved external symbol ". Appetizer code: class EventMgr { template< class T, class EvenT> void RegisterListener(T* listener, int EventType, void (T::*MemFunc)(EvenT*) ); } SoundMgr(which is a listener) tries to register for event: SoundMgr::SoundMgr(void) { EventManager::GetInstance()->RegisterListener(this, 1, (&SoundMgr::handleBulletFired)); } I'm not sure why it won't link. Why can it not find the reference types ? If you simply declared the