gregbackus
Programmer
I'm new to this site and I love it already!
Anyway - down to business -
I'm using 4.52, coding a vector class using templates
(template<class T> class vector)
I've got a header that contains only the declarations of the class and its functions
and a seperate file with the function definitions
(template<class T>
return_value vector<T>::func_name(args,...) --- like that )
I compile the function def file and put it into a library, but invariably I get unresolved
symbol errors. Always the same two functions. If I have the functions defined in the
same file as the class declaration, everything works fine (but TEXT segment is
too big. WAY too big).
so - are there tricks when using libraries that contain templatized classes/functions?
I've tried extern "C" wrappers, explicit cdecl declarations, nothing seems to do the trick.
Any ideas or experiences?
Thanks
Anyway - down to business -
I'm using 4.52, coding a vector class using templates
(template<class T> class vector)
I've got a header that contains only the declarations of the class and its functions
and a seperate file with the function definitions
(template<class T>
return_value vector<T>::func_name(args,...) --- like that )
I compile the function def file and put it into a library, but invariably I get unresolved
symbol errors. Always the same two functions. If I have the functions defined in the
same file as the class declaration, everything works fine (but TEXT segment is
too big. WAY too big).
so - are there tricks when using libraries that contain templatized classes/functions?
I've tried extern "C" wrappers, explicit cdecl declarations, nothing seems to do the trick.
Any ideas or experiences?
Thanks