This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

What's wrong with C51 conditional compiled?

#define RR0  1
#define RR1  0

void main()
{
...
#if RR0
precedure0();
#elif RR1
precedure1();
#endif
...
}
when compiled ,main() 'LCALL' precedure0(),just right.but when definition changed ,as following:
#define RR0 0
#define RR1 1

the program can never be compiled and link.can you tell me what the matter is ?

Best regards,
Nantiangumo

Parents
  • "There is mistake with 'procedure1()',so it can't be compiled and linked."

    It's always best to pay attention to the specific error messages first.

    Remember, if you double-click a compiler error message, it will take you straight to the relevant 'C' source line;

    Also, select any error message, then press F1, and you will get help on the specific message.

Reply
  • "There is mistake with 'procedure1()',so it can't be compiled and linked."

    It's always best to pay attention to the specific error messages first.

    Remember, if you double-click a compiler error message, it will take you straight to the relevant 'C' source line;

    Also, select any error message, then press F1, and you will get help on the specific message.

Children
No data