日韩av黄I国产麻豆传媒I国产91av视频在线观看I日韩一区二区三区在线看I美女国产在线I麻豆视频国产在线观看I成人黄色短片

歡迎訪問 生活随笔!

生活随笔

當(dāng)前位置: 首頁 >

matlab 28m35,使用F28M35添加自己写的头文件时,出现了“XXX”has already been declared in the current scope的问题...

發(fā)布時間:2024/3/12 53 豆豆
生活随笔 收集整理的這篇文章主要介紹了 matlab 28m35,使用F28M35添加自己写的头文件时,出现了“XXX”has already been declared in the current scope的问题... 小編覺得挺不錯的,現(xiàn)在分享給大家,幫大家做個參考.

struct TODAY_BIT {

Uint16 MORNING:16;

Uint16 AFTERNOON:16;

};

union TODAY_REG{

Uint32 all;

struct TODAY_BIT bit;

};

我在頭文件里寫了上述兩組結(jié)構(gòu),然后出現(xiàn)了如下的報錯:

Description Resource Path Location Type

"TODAY_BIT" has already been declared in the current scope ECAN_T&R.h /BasedOnCan_M3_2_Eyior line 44 C/C++ Problem

Description Resource Path Location Type

"TODAY_BIT" has already been declared in the current scope ECAN_T&R.h /BasedOnCan_M3_2_Eyior line 44 C/C++ Problem

***************************************************************************************************************************************************

分割線

***************************************************************************************************************************************************

因?yàn)轭^文件里面的內(nèi)容是自己寫的,所以不存在重復(fù)定義的問題。至于為什么提示重復(fù)聲明,我真的不知道。

求大神解答,這個問題困惑我很久了。

附頭文件全部代碼:

//###########################################################################

//

// FILE: Pepsi_wall.h

//

//###########################################################################

#define ECAN_R&T;

#ifdef __cplusplus

extern "C" {

#endif

/*******************************************

* define a struct type for resister T and R

*******************************************/

struct WALL_BIT{

Uint16 rock0:16;

Uint16 rock1:16;

};

union WALL_REG{

Uint32 all;

struct WALL_BIT bit;

};

struct CLASSROOM_BIT{

union WALL_REG wall0;

union WALL_REG wall1;

};

/*********************************************/

/*******************************************

* define a struct type for resister T and R

*******************************************/

struct TODAY_BIT {

Uint16 MORNING:16;

Uint16 AFTERNOON:16;

};

union TODAY_REG{

Uint32 all;

struct TODAY_BIT bit;

};

/**********************************************/

/*******************************************

* define a struct type for order

*******************************************/

struct ORDER_BIT{

Uint16 order0:1;

Uint16 order1:1;

Uint16 order2:1;

Uint16 order3:1;

Uint16 order4:1;

Uint16 order5:1;

Uint16 order6:1;

Uint16 order7:1;

Uint16 order8:1;

Uint16 order9:1;

Uint16 order10:1;

Uint16 order11:1;

Uint16 order12:1;

Uint16 order13:1;

Uint16 order14:1;

Uint16 order15:1;

Uint16 order16:1;

Uint16 order17:1;

Uint16 order18:1;

Uint16 order19:1;

Uint16 order20:1;

Uint16 order21:1;

Uint16 order22:1;

Uint16 order23:1;

Uint16 order24:1;

Uint16 order25:1;

Uint16 order26:1;

Uint16 order27:1;

Uint16 order28:1;

Uint16 order29:1;

Uint16 order30:1;

Uint16 order31:1;

};

union ORDER_REG{

Uint32 all;

struct ORDER_BIT bit;

};

/*****************************************************************************************************************************/

完畢 ?求大神解答,這個問題困惑我很久了。

總結(jié)

以上是生活随笔為你收集整理的matlab 28m35,使用F28M35添加自己写的头文件时,出现了“XXX”has already been declared in the current scope的问题...的全部內(nèi)容,希望文章能夠幫你解決所遇到的問題。

如果覺得生活随笔網(wǎng)站內(nèi)容還不錯,歡迎將生活随笔推薦給好友。