Visual Studio dll export issue for class and function template instantiations
问题 I am using VS2008 in win7 and g++ 4.7 in CentOS 18. The issue is only seen on Windows when I used dynamically shared library. When I convert it static library the program links fine. I understand that in shared library template functions/class either should be defined in header file or template instantiation of the template types(parameters) should be provided through compilation unit. I have chosen the later option. I have done it before, I went through Why can templates only be implemented