Skip to content

Commit

Permalink
remove tasty escape hatch for 3.2.0-RC4
Browse files Browse the repository at this point in the history
  • Loading branch information
bishabosha committed Sep 1, 2022
1 parent af56abc commit 0aa6bd4
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 14 deletions.
4 changes: 2 additions & 2 deletions project/DottySupport.scala
Expand Up @@ -12,7 +12,7 @@ import sbt.librarymanagement.{
* Settings to support validation of TastyUnpickler against the release of dotty with the matching TASTy version
*/
object TastySupport {
val supportedTASTyRelease = "3.2.0-RC4" // TASTy version 28.2-1
val supportedTASTyRelease = "3.2.0" // TASTy version 28.2-0
val scala3Compiler = "org.scala-lang" % "scala3-compiler_3" % supportedTASTyRelease
val scala3Library = "org.scala-lang" % "scala3-library_3" % supportedTASTyRelease

Expand All @@ -26,7 +26,7 @@ object TastySupport {
* Dotty in .travis.yml.
*/
object DottySupport {
val dottyVersion = "3.2.0-RC4"
val dottyVersion = "3.2.0"
val compileWithDotty: Boolean =
Option(System.getProperty("scala.build.compileWithDotty")).map(_.toBoolean).getOrElse(false)
lazy val commonSettings = Seq(
Expand Down
20 changes: 8 additions & 12 deletions src/compiler/scala/tools/tasty/TastyHeaderUnpickler.scala
Expand Up @@ -44,18 +44,14 @@ class TastyHeaderUnpickler(reader: TastyReader) {
start
}

val validVersion = {
val stdCheck = TastyFormat.isVersionCompatible(
fileMajor = fileMajor,
fileMinor = fileMinor,
fileExperimental = fileExperimental,
compilerMajor = MajorVersion,
compilerMinor = MinorVersion,
compilerExperimental = ExperimentalVersion
)
val fallback = fileMajor == 28 && fileMinor == 2 && fileExperimental == 1 // 3.2.0-RC1
stdCheck || fallback
}
val validVersion = TastyFormat.isVersionCompatible(
fileMajor = fileMajor,
fileMinor = fileMinor,
fileExperimental = fileExperimental,
compilerMajor = MajorVersion,
compilerMinor = MinorVersion,
compilerExperimental = ExperimentalVersion
)

check(validVersion, {
val signature = signatureString(fileMajor, fileMinor, fileExperimental)
Expand Down

0 comments on commit 0aa6bd4

Please sign in to comment.