将JVM args传递给SBT

Syn*_*sso 5 scala jvm-arguments sbt

我的SBT构建回应:

[error] Note: Some input files use unchecked or unsafe operations.
[error] Note: Recompile with -Xlint:unchecked for details.
Run Code Online (Sandbox Code Playgroud)

如何将-Xlint:unchecked参数传递给SBT调用的javac进程?

huy*_*hjl 6

请参阅http://code.google.com/p/simple-build-tool/wiki/BuildConfiguration#Compile_Options

override def compileOptions = super.compileOptions ++ 
  compileOptions("-Xlint:unchecked")
Run Code Online (Sandbox Code Playgroud)

  • 谢谢.这可行,但我认为它是scalac是不正确的.Javac正在呈现错误消息.那个页面给了我正确的答案......`覆盖def javaCompileOptions = super.javaCompileOptions ++ javaCompileOptions(" - Xlint:unchecked")` (2认同)