如何在Eclipse中添加-Xlint:unchecked选项或任何javac选项? [英] How to add -Xlint:unchecked option or any javac option in Eclipse?
问题描述
如何在Eclipse中添加-Xlint:unchecked选项或任何javac选项?
How can i to add -Xlint:unchecked option or any javac option in Eclipse? this is strange there is no obvious way to do that in eclipse.
提前感谢
推荐答案
首先,转到首选项窗口。如果你运行的是Windows或Linux,它将在窗口菜单下,如果你使用Mac OSX,它将在Eclipse菜单下。然后转到 Java - >编译器 - >错误/警告 - >通用类型
,您将看到三个未经检查的类型和操作的编译器警告/错误选项。将其从错误或警告中更改为忽略。
First, go to the Preferences window. If you're running Windows or Linux, it'll be under the 'Window' menu, if you're using Mac OSX it'll be under the 'Eclipse' menu. Then go to Java -> Compiler -> Errors / Warnings -> Generic Types
and you'll see three options for compiler warnings / errors on unchecked types and operations. Chang them from error or warning to ignore.
这篇关于如何在Eclipse中添加-Xlint:unchecked选项或任何javac选项?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!