jkelly061597
asked on
Redefined symbols on link
Hello,
I have a VC6 project I'm trying to compile however I get a ton of "already defined" messages on linking. I am pretty sure this is due to including files where they shouldn't be so can someone give me a rundown on where includes should go?
Here are the basics of the includes by file:
driver.cpp
#include "..\state.h"
state.cpp
#include "state.h"
#include "packet.h"
player.cpp
#include "player.h"
#include "deck.h"
deck.h
hopper.h
#include "deck.h"
player.h
state.h
Every function I call in player, hopper or deck results in something like this:
state.obj : error LNK2005: "public: __thiscall ADeck::ADeck(void)" (??0ADeck@@QAE@XZ) already defined in StateTester.obj
Thanks for the help
I have a VC6 project I'm trying to compile however I get a ton of "already defined" messages on linking. I am pretty sure this is due to including files where they shouldn't be so can someone give me a rundown on where includes should go?
Here are the basics of the includes by file:
driver.cpp
#include "..\state.h"
state.cpp
#include "state.h"
#include "packet.h"
player.cpp
#include "player.h"
#include "deck.h"
deck.h
hopper.h
#include "deck.h"
player.h
state.h
Every function I call in player, hopper or deck results in something like this:
state.obj : error LNK2005: "public: __thiscall ADeck::ADeck(void)" (??0ADeck@@QAE@XZ) already defined in StateTester.obj
Thanks for the help
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.