初级会员

- 积分
- 147
- 金钱
- 147
- 注册时间
- 2018-11-28
- 在线时间
- 37 小时
|
在移植一个嵌入式上下文切换例子中时,有点不太理解#if defined(__CC_ARM) || (defined(__ARMCC_VERSION) && __ARMCC_VERSION >= 6000000) extern const unsigned int cEvent$$Base;
extern const unsigned int cEvent$$Limit;
#elif defined(__ICCARM__) || defined(__ICCRX__)
#pragma section="cEvent"
#elif defined(__GNUC__)
extern const unsigned int _cevent_start;
extern const unsigned int _cevent_end;
#endif
这段代码中
extern const unsigned int cEvent$$Base;
extern const unsigned int cEvent$$Limit;
的意思是什么?我觉得只是声明了一个变量,但是在原文的例子中又没有找到相对应的定义??直接编译的结果报错

直接在源文件中定义还是报一样的错误??
具体的例子原文连接如下:https://github.com/NevermindZZT/cpost
|
|