I need to modify a library that is used by a C-Scripting application to allow a MFC application to stop and start the processing.
However I get the compiler error C2059 at the code snip below:-
#define DLLDIR __declspec(dllexport) // export DLL information
// The extern "C" declaration allows mixed languages compactability, it prevents
// the C++ compiler from using decorated (modified) names for the functions
extern "C" { <-------- Error here !!!!!!!!!!!
void DLLDIR SetAbortFlag(int);
int DLLDIR GetAbortFlag(void);
};
static int abortFlag; /* The flag to abort the test */
static int contiuneFlag; /* The flag to schedule the test to continue */
static int enterFlag; /* The flag to schedule data entry the test */
int APPGetAbortFlag()
{
return abortFlag;
}
void APPSetAbortFlag(int a)
{
if(a == 1)
abortFlag = 1;
else
abortFlag = 0;
}
However I get the compiler error C2059 at the code snip below:-
#define DLLDIR __declspec(dllexport) // export DLL information
// The extern "C" declaration allows mixed languages compactability, it prevents
// the C++ compiler from using decorated (modified) names for the functions
extern "C" { <-------- Error here !!!!!!!!!!!
void DLLDIR SetAbortFlag(int);
int DLLDIR GetAbortFlag(void);
};
static int abortFlag; /* The flag to abort the test */
static int contiuneFlag; /* The flag to schedule the test to continue */
static int enterFlag; /* The flag to schedule data entry the test */
int APPGetAbortFlag()
{
return abortFlag;
}
void APPSetAbortFlag(int a)
{
if(a == 1)
abortFlag = 1;
else
abortFlag = 0;
}