Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add -release 8 scalac option #3006

Merged
merged 2 commits into from
Jun 1, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions build.sbt
Original file line number Diff line number Diff line change
Expand Up @@ -168,6 +168,7 @@ val commonSettings = Sonatype.sonatypeSettings ++ assemblySettings ++ Seq(
Seq()
}
},
Compile / doc / scalacOptions --= Seq("-release", "8"),
scalacOptions in (Compile, doc) ++= Scalac.compileDocOptions.value,
javacOptions ++= Seq("-source", "1.8", "-target", "1.8", "-Xlint:unchecked"),
javacOptions in (Compile, doc) := Seq("-source", "1.8"),
Expand Down Expand Up @@ -1073,6 +1074,7 @@ lazy val `scio-repl`: Project = project
.settings(commonSettings)
.settings(macroSettings)
.settings(
scalacOptions --= Seq("-release", "8"),
libraryDependencies ++= Seq(
"org.scala-lang.modules" %% "scala-collection-compat" % scalaCollectionCompatVersion,
"org.apache.beam" % "beam-runners-direct-java" % beamVersion,
Expand Down
2 changes: 2 additions & 0 deletions project/ScalacOptions.scala
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,8 @@ import sbt._, Keys._
object Scalac {
// see: https://tpolecat.github.io/2017/04/25/scalac-flags.html
val baseOptions = List(
"-release",
"8",
"-target:jvm-1.8",
"-deprecation", // Emit warning and location for usages of deprecated APIs.
"-feature", // Emit warning and location for usages of features that should be imported explicitly.
Expand Down