"#警告"不总是被显示在错误列表 [英] "#warning" not always being shown in the Error List

查看:156
本文介绍了"#警告"不总是被显示在错误列表的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我用这个标记code,我需要回过头来:

I use this to mark code I need to come back to:

#warning Do more stuff here

不过,有时候这些警告不要在构建后错误列表窗口中显示出来。我可以看到在编译器输出窗口的警告,但只有其中的一些使之成为错误列表。如果我有了这些警告,他们始终显示在code文件打开。如果我有code文件关闭,他们不会出现的大部分时间。有没有设置,我可以更改为错误列表调整此行为,并始终显示的警告?

However, sometimes these warning don't show up in the Error List window after a build. I can see the warnings in the compiler output window, but only some of them make it into the Error List. If I have the code file open that has these warnings they are always shown. If I have the code file closed, they don't appear most of the time. Is there a setting I can change to adjust this behaviour and always show the warnings in the Error List?

推荐答案

原因在于,即使当报警发生时,编译器通常认为这个源文件是确定。因此,在增量生成,源文件不会重新编译,并且不显示警告。

The reason is that, even if a warning occurs, the compiler normally considers this source file to be ok. So in an incremental build, the source file isn't recompiled, and the warning isn't displayed.

这篇关于"#警告"不总是被显示在错误列表的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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