From: <Joe...@ao...> - 2003-09-01 01:52:33
|
I am used to using VC++ 6.0 & templates. I have found out that I have to explicitly instantiate templates (after reading Tom Swan's GNU C++ book). Are there some examples/tutorials that show exmaples of all the possibility for link with templates under mingw? Explicit instantiation is nice when you know know everything you want to use the template with, but that may not be the case. I would prefer to have the compiler automatically instantiate the instances of templates. I understand that explicit instantiation can make for cleaner code, but it seems to defeat the purpose of templates. How is the undefined reference problem gotten around in the STL for user defined templates? Thank you in advance. Joe M. |