// A.cpp
#include "A.h"
// A.h
#ifndef _A_H
#define _A_H
class A
{
public:
A();
~A();
private:
};
A::A()
{
}
A::~A()
{
}
#endif
// test.cpp
#include "A.h"
int main(){
}
Then error LNK2005: "public: void __thiscall" will appear when compiling. When deleting the constructor and destructor, it can pass? Why? What should I do if I still can't compile the runtime library by changing the runtime library as mentioned on the Internet? ?
Have you posted the complete code? I am running it normally in vs2015.