You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In Dotty, we've encountered a problem that the Dotty's version of ClassfileParser presumably fell behind the Scala 2's one (see scala/scala3#6136). This appears to be a specific case of a more general problem of code sharing between Scala 2 and 3. In this issue, I propose to discuss the ways we can keep the Scala 2 and 3 components DRY and in sync.
I believe the following questions need to be answered:
What code repeats between Dotty and Scala 2?
What considerations do we need to take into account when sharing between Dotty and Scala 2? What are the obstacles?
How do we share the code?
Regarding the second point, I suppose one obstacle would be the coupling it creates between Dotty and Scala 2. The changes to Scala 2 and Dotty may affect each other, and this complicates experimentation.
Another consideration is that the code bases are big, and it may take a lot of work to see what can be shared and to actually share it.
@adriaanm, would love to hear your opinion on the above.
The text was updated successfully, but these errors were encountered:
I think we should invest in sharing code, and we'll soon have time to start working on this (when 2.13.0 is out). I'm very open to change scalac internals/APIs to make this happen, to reorganize source folders, git submodules,....
Let's start with the backend (genbcode + optimizer), and figure out how to define an interface that works for both frontends with minimal glue code. I suppose it will have to be compiled from source against both frontends for best performance, but if we can find a way to share a binary artifact, that would be amazing.
In Dotty, we've encountered a problem that the Dotty's version of ClassfileParser presumably fell behind the Scala 2's one (see scala/scala3#6136). This appears to be a specific case of a more general problem of code sharing between Scala 2 and 3. In this issue, I propose to discuss the ways we can keep the Scala 2 and 3 components DRY and in sync.
I believe the following questions need to be answered:
Regarding the second point, I suppose one obstacle would be the coupling it creates between Dotty and Scala 2. The changes to Scala 2 and Dotty may affect each other, and this complicates experimentation.
Another consideration is that the code bases are big, and it may take a lot of work to see what can be shared and to actually share it.
@adriaanm, would love to hear your opinion on the above.
The text was updated successfully, but these errors were encountered: