I am new to Scala, Scala -IDE and Play 2.1, and I'm going through tutorials. Today I noticed that the Eclipse project, released by the todolist tutorial, appears in Scala -IDE with a warning that I do not understand and would like to leave.
This answer How do I get more information about warning the 'feature' flag? suggests that I only need to add ...
scalacOptions ++= Seq(... "-feature")
... to my sbt build definition file, which I thought was the /Build.scala project for the Play 2.1 project. Trying to put it there, however ...
import sbt._ import Keys._ import play.Project._ object ApplicationBuild extends Build { val appName = "todolist" val appVersion = "1.0-SNAPSHOT" val appDependencies = Seq( // Add your project dependencies here, jdbc, anorm ) val main = play.Project(appName, appVersion, appDependencies).settings( // Add your own project settings here scalacOptions ++= Seq(... "-feature") ) }
... leads to a compilation error ...
[info] Loading project definition from /Users/bobk/work/todolist/project [error] /Users/bobk/work/todolist/project/Build.scala:18: illegal start of simple expression [error] scalacOptions ++= Seq(... "-feature") [error] ^ [error] /Users/bobk/work/todolist/project/Build.scala:21: ')' expected but '}' found. [error] } [error] ^ [error] two errors found [error] (compile:compile) Compilation failed Project loading failed: (r)etry, (q)uit, (l)ast, or (i)gnore?
If I want to set scalacOptions in my sbt build definition in Play 2.1, where can I specify it and how?
source share