Yes, I always use level 4 warnings.
Originally Posted by cpjust
I also ticked every option for warnings I could find in GCC. Both pedantic and -wall.
Well... I would say yes, seeing as it must have access to internals to assign.
Re: friend functions
Why would your == operators need to be friends? As long as they don't try to use any private data or functions, they can be non-member AND non-friend functions.
But even if not, I'd like to understand how it works.
Hmmm. I don't see WinDiff.
Re: Diff program
I believe the non-express VC++ should come with WinDiff, but I prefer the Diff program in Perforce. You should install Perforce anyways, if you don't already have a version control system. http://www.perforce.com/
It's free to use for single-user usage, and it's much more intuitive and easier to use than something like CVS or even VSS.
I'll check out Perforce.
Ah, it compiles now.
I'm guessing the <> tags plus explicit template tags are required to compile it correctly. That plus you need declarations of the template names that you reference with the templates:
Green = Explicit type for the class
friend CTmplStringBase<T, Traits>& operator += <> (CTmplStringBase<T, Traits>& rlhs, const T* strData);
Red = Needed to mention it's a template I guess.
Needed to tell the compiler the template names mentioned above really do exist.
template<typename T, typename Traits> class CTmplStringBase;