Skip to content

Commit

Permalink
Merge pull request #785 from scala-steward/update/scala-library-2.13.12
Browse files Browse the repository at this point in the history
  • Loading branch information
dwijnand committed Sep 25, 2023
2 parents be3968d + 79d1a8c commit 6441c31
Show file tree
Hide file tree
Showing 6 changed files with 19 additions and 9 deletions.
13 changes: 10 additions & 3 deletions build.sbt
Original file line number Diff line number Diff line change
Expand Up @@ -18,9 +18,16 @@ inThisBuild(Seq(
))

def compilerOptions(scalaVersion: String): Seq[String] =
Seq("-feature", "-Wconf:cat=deprecation&msg=Stream|JavaConverters:s") ++
Seq(
"-feature",
"-Wconf:cat=deprecation&msg=Stream|JavaConverters:s",
) ++
(CrossVersion.partialVersion(scalaVersion) match {
case Some((2, _)) => Seq("-Xsource:3", "-Xlint")
case Some((2, _)) => Seq(
"-Xsource:3", "-Xlint",
// these are too annoying when crossbuilding
"-Wconf:cat=unused-nowarn:s",
)
case _ => Seq()
})

Expand All @@ -35,7 +42,7 @@ commands += Command.command("testStaging") { state =>

// Keep in sync with TestCli
val scala212 = "2.12.18"
val scala213 = "2.13.11"
val scala213 = "2.13.12"
val scala3 = "3.3.1"

val root = project.in(file(".")).settings(
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
package com.typesafe.tools.mima.core

import scala.annotation.tailrec
import scala.annotation.{nowarn, tailrec}
import scala.collection.mutable

sealed class SyntheticPackageInfo(val owner: PackageInfo, val name: String) extends PackageInfo {
Expand All @@ -9,9 +9,10 @@ sealed class SyntheticPackageInfo(val owner: PackageInfo, val name: String) exte
lazy val classes = Map.empty[String, ClassInfo]
}

@nowarn("msg=under -Xsource:3, inferred") // return types are a bit different between 2 and 3 but it's fine afaics
object NoPackageInfo extends PackageInfo {
val name = "<no package>"
val owner = this
val owner = this
def definitions = sys.error("Called definitions on NoPackageInfo")
val packages = mutable.Map.empty[String, PackageInfo]
val classes = Map.empty[String, ClassInfo]
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ package com.typesafe.tools.mima.core

import java.util.UUID

import scala.annotation.tailrec
import scala.annotation.{nowarn, tailrec}
import scala.collection.mutable, mutable.{ ArrayBuffer, ListBuffer }

import TastyFormat._, NameTags._, TastyTagOps._, TastyRefs._
Expand Down Expand Up @@ -438,6 +438,7 @@ object TastyUnpickler {

final case class SimpleName(raw: String) extends Name
final case class ObjectName(base: Name) extends Name
@nowarn("msg=constructor modifiers are assumed by synthetic")
final case class TypeName private[TastyUnpickler] (base: Name) extends Name
final case class QualifiedName(qual: Name, sep: SimpleName, sel: SimpleName) extends Name

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,8 @@ final class TestCase(val baseDir: Directory, val scalaCompiler: ScalaCompiler, v
val opts = List("-classpath", cpStr, "-d", s"$out").asJava
val units = sourceFiles.map { sf =>
new SimpleJavaFileObject(new URI(s"string:///${sf.path}"), JavaFileObject.Kind.SOURCE) {
override def getCharContent(ignoreEncodingErrors: Boolean) = java.nio.CharBuffer.wrap(sf.content)
override def getCharContent(ignoreEncodingErrors: Boolean): java.nio.CharBuffer =
java.nio.CharBuffer.wrap(sf.content)
}
}.asJava
val infos = new mutable.LinkedHashSet[Diagnostic[_ <: JavaFileObject]]
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ object TestCli {
// Keep in sync with build.sbt
val scala211 = "2.11.12"
val scala212 = "2.12.18"
val scala213 = "2.13.11"
val scala213 = "2.13.12"
val scala3 = "3.3.1"
val hostScalaVersion = StdLibProps.scalaPropOrNone("maven.version.number").get
val allScalaVersions = List(scala211, scala212, scala213, scala3)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ organization := "com.typesafe"
name := "pom-only-project"
version := "1.1.0"
mimaPreviousArtifacts := Set(organization.value %% moduleName.value % "1.0.0")
scalaVersion := "2.13.11"
scalaVersion := "2.13.12"

// this is an arbitrary dependency, but one that's known to cause issues in POM-only projects
// see https://github.com/lightbend/mima/issues/768 for more context
Expand Down

0 comments on commit 6441c31

Please sign in to comment.