Skip to content

Commit

Permalink
chore: Allow to write tasty for Scala2 symbols under -Ycompile-scala2…
Browse files Browse the repository at this point in the history
…-library
  • Loading branch information
hamzaremmal committed Feb 7, 2025
1 parent 965dbfa commit 78c7473
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 3 deletions.
2 changes: 1 addition & 1 deletion compiler/src/dotty/tools/dotc/core/tasty/TreePickler.scala
Original file line number Diff line number Diff line change
Expand Up @@ -861,7 +861,7 @@ class TreePickler(pickler: TastyPickler, attributes: Attributes) {
assert(isModifierTag(tag))
writeByte(tag)
}
assert(!flags.is(Scala2x))
if flags.is(Scala2x) then assert(attributes.scala2StandardLibrary)
if (flags.is(Private)) writeModTag(PRIVATE)
if (flags.is(Protected)) writeModTag(PROTECTED)
if (flags.is(Final, butNot = Module)) writeModTag(FINAL)
Expand Down
2 changes: 0 additions & 2 deletions project/Scala2LibraryBootstrappedMiMaFilters.scala
Original file line number Diff line number Diff line change
Expand Up @@ -66,8 +66,6 @@ object Scala2LibraryBootstrappedMiMaFilters {
ProblemFilters.exclude[FinalMethodProblem]("scala.io.Source.NoPositioner"),
ProblemFilters.exclude[FinalMethodProblem]("scala.io.Source.RelaxedPosition"),
ProblemFilters.exclude[FinalMethodProblem]("scala.io.Source.RelaxedPositioner"),
ProblemFilters.exclude[IncompatibleResultTypeProblem]("scala.reflect.ManifestFactory#NothingManifest.newArray"),
ProblemFilters.exclude[IncompatibleResultTypeProblem]("scala.reflect.ManifestFactory#NullManifest.newArray"),
ProblemFilters.exclude[MissingFieldProblem]("scala.collection.ArrayOps#ReverseIterator.xs"),
ProblemFilters.exclude[MissingFieldProblem]("scala.runtime.NonLocalReturnControl.value"),
) ++
Expand Down

0 comments on commit 78c7473

Please sign in to comment.