We are running a survey to help us improve the experience for all of our members. If you see the survey appear, please take the time to tell us about your experience if you can.
After upgrading to 7.02b, I get a C258 Warning when using the typedef in the following example. If I use 'bit' directly, the Warning is not issued. Any clues? Best regards and thanks in advance. Jose
volatile unsigned char c1, c2, c3; typedef bit BOOL; unsigned char func1(BOOL a, unsigned char b) { if (a) return b; else return ~b; } void main(void) { c1 = func1(0, 9); c2 = func1(1, 8); }
Some more information on the issue: If the parameters are swapped, the Warning is not issued. In the following example, func1 generates the following warning:
MAIN.C(5): warning C258: 'b': mspace on parameter ignored
unsigned char func1(BOOL a, unsigned char b) { if (a) return b; else return ~b; } unsigned char func2(unsigned char b, BOOL a) { if (a) return b; else return ~b; }