This thread has been locked.
If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.
在构建一些包含driverlib.h的代码时,我收到以下警告
../../driverlib/inc/MSP_compatibility.h:145:41:警告:函数'ASM'的隐式声明[-Wimplicit-function-declaration]
#define __wfi() ASM(" wfi")
^
../../driverlib/inc/MSP_compatibility.h:146:41:注:在宏'__wfi'的扩展中
#define __sleep()__wfi()
^
./src/sp_lpm.c:274:8:注:在扩展宏'__sleep'时
__sleep();
仅当我使用gcc编译标志 -std=c99时才会发生这种情况。 如果我删除它,警告将消失,代码将正常生成,否则它将无法生成。
我的文件包括以下内容:
#include <rom.h>
#include <ROM_map.h>
#include <driverlib.h>
是否应包含任何其他标题才能使其正常工作?
谢谢,此致,
Pedro