Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

Dark GDK / More linker errors..

Author
Message
tomtetlaw
15
Years of Service
User Offline
Joined: 18th Jan 2009
Location:
Posted: 9th Aug 2009 14:56
I am getting this error from the linker:
Compiler Output Version:


Error List Version:


Here is where I define _Point2d:
gclass.h:


gclass.cpp:


And this is where I use it:
Main.cpp:


And I have no idea about linker errors like this, I looked up the error code on the MSDN website, but that provided no help as I can see no place where I refrenced a symbol that I havn't defined..

And help would be appreciated

#ifdef __NEWBIE__
MakeAnAwesomeGame(lots of badies, lots of guns, lots of stuff to do, BIG level)
#endif
IanM
Retired Moderator
22
Years of Service
User Offline
Joined: 11th Sep 2002
Location: In my moon base
Posted: 9th Aug 2009 15:12
With a very few exceptions, you should not put your template functions into .cpp files - they should all go into the header file.

Move the functions in Gclass.cpp to Gclass.hpp.

TheGroggyOne
15
Years of Service
User Offline
Joined: 11th Apr 2009
Location:
Posted: 11th Aug 2009 01:03
export template<typename T> is what you're looking for.

However, VC++ doesn't support it, although they've had it reserved for around 10yrs now.

Login to post a reply

Server time is: 2024-10-01 10:36:15
Your offset time is: 2024-10-01 10:36:15