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

Drop scala3-presentation-compiler-non-bootstrapped #21708

Merged
merged 2 commits into from
Oct 7, 2024
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: 1 addition & 1 deletion .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -228,7 +228,7 @@ jobs:
uses: actions/checkout@v4

- name: Test
run: sbt ";scala3-bootstrapped/compile; scala3-bootstrapped/testCompilation; scala3-presentation-compiler-bootstrapped/test; scala3-language-server/test"
run: sbt ";scala3-bootstrapped/compile; scala3-bootstrapped/testCompilation; scala3-presentation-compiler/test; scala3-language-server/test"
shell: cmd

- name: build binary
Expand Down
1 change: 0 additions & 1 deletion build.sbt
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,6 @@ val `dist-linux-aarch64` = Build.`dist-linux-aarch64`
val `community-build` = Build.`community-build`
val `sbt-community-build` = Build.`sbt-community-build`
val `scala3-presentation-compiler` = Build.`scala3-presentation-compiler`
val `scala3-presentation-compiler-bootstrapped` = Build.`scala3-presentation-compiler-bootstrapped`

val sjsSandbox = Build.sjsSandbox
val sjsJUnitTests = Build.sjsJUnitTests
Expand Down
228 changes: 0 additions & 228 deletions library/src-non-bootstrapped/scala/NamedTuple.scala

This file was deleted.

27 changes: 9 additions & 18 deletions project/Build.scala
Original file line number Diff line number Diff line change
Expand Up @@ -1374,25 +1374,21 @@ object Build {
)

lazy val `scala3-presentation-compiler` = project.in(file("presentation-compiler"))
.asScala3PresentationCompiler(NonBootstrapped)
lazy val `scala3-presentation-compiler-bootstrapped` = project.in(file("presentation-compiler"))
.asScala3PresentationCompiler(Bootstrapped)
.withCommonSettings(Bootstrapped)
.dependsOn(`scala3-compiler-bootstrapped`, `scala3-library-bootstrapped`)
.settings(presentationCompilerSettings)
.settings(scala3PresentationCompilerBuildInfo)
.settings(
// Add `-Yno-flexible-types` flag for bootstrap, see comments for `bootstrappedDottyCompilerSettings`
Compile / scalacOptions += "-Yno-flexible-types"
)

def scala3PresentationCompiler(implicit mode: Mode): Project = mode match {
case NonBootstrapped => `scala3-presentation-compiler`
case Bootstrapped => `scala3-presentation-compiler-bootstrapped`
}

def scala3PresentationCompilerBuildInfo(implicit mode: Mode) =
def scala3PresentationCompilerBuildInfo =
Seq(
ideTestsDependencyClasspath := {
val dottyLib = (dottyLibrary / Compile / classDirectory).value
val dottyLib = (`scala3-library-bootstrapped` / Compile / classDirectory).value
val scalaLib =
(dottyLibrary / Compile / dependencyClasspath)
(`scala3-library-bootstrapped` / Compile / dependencyClasspath)
.value
.map(_.data)
.filter(_.getName.matches("scala-library.*\\.jar"))
Expand Down Expand Up @@ -2284,9 +2280,9 @@ object Build {

// FIXME: we do not aggregate `bin` because its tests delete jars, thus breaking other tests
def asDottyRoot(implicit mode: Mode): Project = project.withCommonSettings.
aggregate(`scala3-interfaces`, dottyLibrary, dottyCompiler, tastyCore, `scala3-sbt-bridge`, scala3PresentationCompiler).
aggregate(`scala3-interfaces`, dottyLibrary, dottyCompiler, tastyCore, `scala3-sbt-bridge`).
bootstrappedAggregate(`scala2-library-tasty`, `scala2-library-cc-tasty`, `scala3-language-server`, `scala3-staging`,
`scala3-tasty-inspector`, `scala3-library-bootstrappedJS`, scaladoc).
`scala3-tasty-inspector`, `scala3-library-bootstrappedJS`, scaladoc, `scala3-presentation-compiler`).
dependsOn(tastyCore).
dependsOn(dottyCompiler).
dependsOn(dottyLibrary).
Expand Down Expand Up @@ -2396,11 +2392,6 @@ object Build {
settings(commonBenchmarkSettings).
enablePlugins(JmhPlugin)

def asScala3PresentationCompiler(implicit mode: Mode): Project = project.withCommonSettings.
dependsOn(dottyCompiler, dottyLibrary).
settings(presentationCompilerSettings).
settings(scala3PresentationCompilerBuildInfo)

def asDist(implicit mode: Mode): Project = project.
enablePlugins(UniversalPlugin, RepublishPlugin).
withCommonSettings.
Expand Down
Loading