如何让这个c宏工作?

Ale*_*vid 1 c

为什么使用on和off宏会产生问题.我是新手使用c宏.宏声明是否正确或代码是否存在其他问题.请帮忙 ??

#include<stdio.h>
#include<stdint.h>

#define ONE 1;             //  OR BY   1 [ 0 0 0 0 0 0 0 1 ] TO insert 1 at LSB position             
#define TWO_FIVE_FOUR 254; // AND BY 254 [ 1 1 1 1 1 1 1 0 ] TO insert 0 at LSB position

#define on(x) (x|ONE)
#define off(x) (x & TWO_FIVE_FOUR)

int main()
{
    uint8_t a=53;

    printf("\nValue of byte a : %d",a );

    printf("\nValue of byte b : %d",on(a)); //Error

    printf("\nValue of byte c : %d",off(a)); //Error

    getchar();

    return 0;
}
Run Code Online (Sandbox Code Playgroud)

Dou*_*rie 6

从宏定义中删除分号

#define ONE 1              //  OR BY   1 [ 0 0 0 0 0 0 0 1 ] TO insert 1 at LSB position             
#define TWO_FIVE_FOUR 254  // AND BY 254 [ 1 1 1 1 1 1 1 0 ] TO insert 0 at LSB position
Run Code Online (Sandbox Code Playgroud)