【发布时间】:2014-12-30 04:21:58
【问题描述】:
我已经在这里搜索了很多次,但作者通常没有提供代码示例,我今天遇到了这个问题,我不太确定如何解决它。
1 个错误列表 bool Init(?@@A_NA) already defined in Client.obj。这是我的 Client.cpp、Main.cpp 和 Main.h 的部分代码。
客户端.cpp
#include "stdafx.h"
#include "Main.h"
// the rest of the code doesn't have anything to do with this error..
Main.h
#include "stdafx.h"
bool Init;
// the rest of the code doesn't have anything to do with this error..
Main.cpp
#include "stdafx.h"
#include "Main.h"
int main()
{
Init = false;
return 0;
}
【问题讨论】:
标签: c++ visual-studio-2010 linker