【发布时间】:2013-07-25 00:08:38
【问题描述】:
在 Qt 项目中编译一组文件时,我看到许多与此类似的警告。
In file included from /usr/local/Trolltech/Qt-4.8.6/include/QtGui/qevent.h:52:
/usr/local/Trolltech/Qt-4.8.6/include/QtGui/qmime.h:119:10: warning: private field 'type' is not used [-Wunused-private-field]
char type;
^
根据各种搜索的建议,我确实添加了条目
QMAKE_CXXFLAGS += -Wno-unused-private-field
到 .pro 文件并确认它在编译器调用中正确显示,但我仍然收到该警告。
我在 Mac 上使用 clang 运行 Qt。
提前感谢您提供任何见解。
【问题讨论】: