Exporting template from dll
I know it's been discussed somewhere before, but I can't find it.
I don't quite remember how to export templates from a dll.
My current code does:
template<typename T> class AFX_EXT_CLASS CTmplString
EXPORT is defined as:
EXPORT template CTmplString<char>;
EXPORT template CTmplString<wchar_t>;
Yet, I get a heap of linker errors for CTmplString<wchar_t>.
#define EXPORT __declspec(dllexport)
#define EXPORT __declspec(dllimport)
Anyone got a pointer? It's supposed to work to export explicit instantiations.