C
Christopher
My book tells me that the compiler will automagically decide whether to
instantiate a basic_iostream with char or wchar_t and I want to do the same
with my class derived from the basic_iostream. I looked at the
implementation of iostream that came with my environment and I found:
#if defined(_DLL_CPPLIB) && !defined(_M_CEE_PURE)
template class _CRTIMP2_PURE basic_iostream<char, char_traits<char> >;
template class _CRTIMP2_PURE basic_iostream<wchar_t, char_traits<wchar_t> >;
my instinct would tell me to put the same defines for my derived class, but
I don't think that would be very portable, as I believe _DLL_CPPLIB,
_M_CEE_PURE, and _CRTIMP2_PURE to be MS specific or worse even compiler
specific. Is there some portable way to accomplish the same thing?
Even if I use #ifdef #endif blocks I wouldn't know what to put in them for
these defines for other OSes/Compilers.
Any advice?
instantiate a basic_iostream with char or wchar_t and I want to do the same
with my class derived from the basic_iostream. I looked at the
implementation of iostream that came with my environment and I found:
#if defined(_DLL_CPPLIB) && !defined(_M_CEE_PURE)
template class _CRTIMP2_PURE basic_iostream<char, char_traits<char> >;
template class _CRTIMP2_PURE basic_iostream<wchar_t, char_traits<wchar_t> >;
my instinct would tell me to put the same defines for my derived class, but
I don't think that would be very portable, as I believe _DLL_CPPLIB,
_M_CEE_PURE, and _CRTIMP2_PURE to be MS specific or worse even compiler
specific. Is there some portable way to accomplish the same thing?
Even if I use #ifdef #endif blocks I wouldn't know what to put in them for
these defines for other OSes/Compilers.
Any advice?