我有四个班级A,B,C和D.
A.H:
<script language="JavaScript" type="text/javascript">
Out = '<a href="file://Dfs.local/I/Test Copy.xls">Report<\/a>';
document.writeln(Out);
</script>
B.h:
#include "B.h"
#include "C.h"
#include "D.h"
class A
{
public:
A() {};
void run() { B b; C c(b); };
};
C.h:
#include "D.h"
class B
{
public:
B() {};
};
D.h:
#include "B.h"
class C
{
public:
C(B b) { m_copy_b = &b; };
int blank(B& b) {}; // LINE 10
private:
B* m_copy_b; // LINE 12
};
我的主要档案:
#include "C.h"
class D
{
public:
D() {};
};
除了代码很糟糕(只是为了示例),编译代码时出现两个错误:
#include "A.h"
int main()
{
A a;
a.run();
return 0;
}
我不知道如何解决它,在我添加D类之前它运作良好...
有什么想法吗?谢谢!