IDE检测到代码中的错误(编译器没有) [英] IDE detects error in code (compiler does not)

查看:73
本文介绍了IDE检测到代码中的错误(编译器没有)的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在使用visual studio 15进行嵌入式C makefile项目,并遇到以下代码问题:

Hi, I am using visual studio 15 for an embedded C makefile project, and experience issues with the following piece of code:

#define STRINGIFY(a)#a

#define STRINGIFY(a) #a

#define PERIPHERAL_ISR(vec)_Pragma(STRINGIFY(interrupt isr _ ## vec ##(vect = ## vec ##)) )void isr _ ## vec ##(void){isr_table [## vec ##](); }

#define PERIPHERAL_ISR(vec) _Pragma(STRINGIFY(interrupt isr_##vec##(vect=##vec##))) void isr_##vec##(void) { isr_table[##vec##](); }

PERIPHERAL_ISR(VECT_S12AD_S12ADI0)

PERIPHERAL_ISR(VECT_S12AD_S12ADI0)

预处理程序指令的调用给出了以下错误:

the call of the preprocessor directive gives me the following error:

预期类型说明符

我的编译器不会生成此错误,而是由IDE生成本身,意味着代码工作正常,但留下了带有红色下划线的代码片段。有谁知道我怎么能避免这个错误?

This error is not generated by my compiler, but by the IDE itself, meaning the code works fine, but leaves me with red underlined pieces of code. does anyone know how I can avoid this error?

提前致谢。

推荐答案

您好,

欢迎来到MSDN论坛。

Welcome to MSDN forum.

此论坛正在讨论Visual Studio WPF / SL Designer,Visual Studio Guidance Automation Toolkit,开发人员文档和帮助系统以及Visual Studio编辑器。 

您的问题与C develop有关,我会将这个帖子移到相应的论坛 专业人士回答。

祝你好运,

Joyce


这篇关于IDE检测到代码中的错误(编译器没有)的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆