本文介绍了-Wundef和-Werror = undef在MinGw 4.4.1中无法一起使用的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

根据GCC文档在#if指令中使用未定义的标识符时,-Wundef发出警告-Werror =将指定的警告显示为错误

According to the GCC documentation-Wundef emits a warning when an undefined identifier is used in a #if directive and-Werror= displays the specified warning as error

但是他们不能在MinGW 4.4.1中一起工作.尽管-Wundef有效,而-Werror(将所有警告显示为错误)有效.

But they are not working together in MinGW 4.4.1. Although -Wundef works and -Werror (to display all warnings as error) work.

这是一个已知问题吗?有可用的解决方法吗?

Is this a known issue? Any workarounds available?

推荐答案

MinGW 4.4.1似乎有问题在4.6.2中像魅力一样工作

Looks like there's a problem with MinGW 4.4.1Worked like a charm in 4.6.2

这篇关于-Wundef和-Werror = undef在MinGw 4.4.1中无法一起使用的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

11-02 11:58