Hello,
I've searched and searched and cannot seem to figure it out so I was
hoping someone could explain to me exactly what an unqualified-id is?
My compiler is generating this error...
ThreadLibMutex.h:37: error: expected unqualified-id before ')'
token
My line 37 is the top of this constructor...
Mutex(){
#ifdef WIN32
// we use critical sections in Windows
InitializeCriticalSection( &m_mutex );
#else
pthread_mutex_init( &m_mutex, 0 );
#endif
}
The class itself is defined immediately above and consists of....
class Mutex {
protected:
// define the base mutex types
#ifdef WIN32
CRITICAL_SECTION m_mutex;
#else
pthread_mutex_t m_mutex;
#endif
public:
inline void Lock() {
#ifdef WIN32
EnterCriticalSection( &m_mutex );
#else
pthread_mutex_lock( &m_mutex );
#endif
}
inline void Unlock() {
#ifdef WIN32
LeaveCriticalSection( &m_mutex );
#else
pthread_mutex_unlock( &m_mutex );
#endif
}
}; // end class Mutex
I've just never heard of an unqualified-id so I have no idea whats
wrong, but the code is looking perfectly legal to me.
Any advice appreciated, and again, thanks in advance!
Regards,