T O P I C R E V I E W |
MBIMO |
Posted - 08/16/2005 : 11:09:20 AM Origin Version (Select Help-->About Origin): 7.0552 SR4 Operating System: Win2k
Hello everybody,
I'm sorry to bother you people with a stupid question, but what's the difference between the two data types BOOL and bool?
If I define two functions:
void Func1(BOOL aBoolean) {}
void Func2(bool aBoolean) {}
and call them in another function e.g.:
void Test() { Func1(TRUE); Func2(true); // <==ERROR }
I get the following error in the marked line when compiling:
Error, Function Func2@_BA was called, but its body could not be located during linking. Linking Failed!
Does anybody know why the second line isn't working?
Thanks in advance,
Martin |
2 L A T E S T R E P L I E S (Newest First) |
MBIMO |
Posted - 08/17/2005 : 02:55:16 AM Hi CP,
thanks for you help.
You are right, meanwhile I managed to run the example on a computer with an Origin 7.5 installation without any problems.
Thanks again,
Martin |
cpyang |
Posted - 08/16/2005 : 12:16:57 PM Maybe there was a bug in 7.0, but 7.5 should not have problem.
BOOL is typedef as int, and bool is internally char type. Reason for the two was for calling external DLL function which might have the two types. If all codes are inside OC, we usually just use bool.
CP
|
|
|