CCS3.3非标准位域出现的警告,附程序
编译器如何设置可以消除这种警告呢?struct CMD_BITS
{ // bit description
LINE:45 UINT32 Bfa:10; // 10 Don't care bits/BufferAddess bits
LINE:46 UINT32 PageAddr:12;// 12 Page Addr bits
LINE:47 UINT32 Rsvd2:2; // 2 Don't care bits
LINE:48 UINT32 OpCode:8; // 8 Op Code bits
};
struct CMD_WORD
{
LINE:53 UINT32 low:16;
LINE:54 UINT32 high:16;
};
union AT45_CMD
{
structCMD_WORDword;
structCMD_BITSbit;
};
"drv_spi.c", line 45: warning: nonstandard type for a bit field
"drv_spi.c", line 46: warning: nonstandard type for a bit field
"drv_spi.c", line 47: warning: nonstandard type for a bit field
"drv_spi.c", line 48: warning: nonstandard type for a bit field
"drv_spi.c", line 53: warning: nonstandard type for a bit field
"drv_spi.c", line 54: warning: nonstandard type for a bit field 我也遇到了. 但是好像对程序的运行没有影响
页:
[1]