Reputation: 407
I am getting "error: cannot declare pointer to 'void' member" for below code.
template <class T>
DtRequestId Notify(T* pObject, void (T::*callback)(Status*));
can somebody please help?
Upvotes: 0
Views: 171
Reputation: 181745
I get this error when I compile this (whole file):
typedef int DtRequestId;
template <class T>
DtRequestId Notify(T* pObject, void (T::*callback)(Status*));
But if I also define Status
, the error goes away:
typedef int DtRequestId;
typedef int Status;
template <class T>
DtRequestId Notify(T* pObject, void (T::*callback)(Status*));
So maybe you forgot to give a definition of Status
.
Upvotes: 2