You need to add a function prototype for bool func() before you call it from main, if that's what you're doing. Like this:
EDIT:Code:#define ......
/*function prototype*/
bool func();
int main()
{
}
bool func() /**bool is taken care of and works fine**/
{
defined function is called here as explained above
}
Say you have the code
Now, the compiler is going to go along like thisCode:int main()
{
a();
}
void a()
{
/* do something */
}
Ok here's the main function, I'll just dive into it and start compiling the code in there. Hmm, "a();", I've never seen "a" before, what's it supposed to be? Wait, you're calling it? Does that mean it's a function? Could it be a typo? For that matter, it's not even supposed to exist! I guess I'll just have to throw an error as I'm not smart enough to look ahead.
Hope that clears the function prototype issue up if that is a problem, I'm not sure exactly what the problem is.