I have code that contains these declarations:
class IRealNetDll;
extern "C"__declspec(dllexport)
IRealNetDll * CreateRealInstance(int ilicence);
This builds properly with Visual Studio 2012 on Win7.
But on VS 2015, 2017 on Windows 10, this line:
extern "C"__declspec(dllexport)
results in:
error C4430: missing type specifier - int assumed. Note: C++ does not support default-int
error C3690: expected a string literal, but found a user-defined string literal instead
error C4430: missing type specifier - int assumed. Note: C++ does not support default-int
error C2146: syntax error: missing ';' before identifier 'IRealNetDll'
Why do I get this error, why only on the newer compiler, and how can I prevent it?