I am new to C ++. Today I have a problem: in the header file, I define the class:
template<class T> class Ptr_to_const { private: Array_Data<T>* ap; unsigned sub; public: ... Ptr_to_const<T> & operator=(const Ptr_to_const<T> & p); };
and in the source file I program as:
template<class T> Ptr_to_const<T>& Ptr_to_const<T>::operator=( const Ptr_to_const<T> & p) { ... return *this; }
when compiling, the compiler always says: ' Member declaration not found . why?
I am using eclipse CDT + Cygwin GCC
Thank you very much!
c ++ declaration member
wenfeng
source share