Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit42fdd76

Browse files
authored
chore: make metals believe scala-library-bootstrapped is a scala 3 project (#23568)
If we don't set explicitly the scala version, sbt will default to `2.12`which will be then used by metals, even when we actually override thescalaInstance when bootstrapping. In this PR, we actually make sure thatthe stdlib bootstrapped uses a Scala 3 version so that metals won'tconfuse it with a scala 2.12 project.<img width="1200" height="42" alt="Screenshot 2025-07-18 at 20 45 30"src="https://github.com/user-attachments/assets/bc1a66c0-48c3-4dea-9d64-3f651170ef72"/>
2 parents5899730 +dd93b12 commit42fdd76

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

‎project/Build.scala

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1450,6 +1450,9 @@ object Build {
14501450
moduleName:="scala-library",
14511451
version:= dottyVersion,
14521452
versionScheme:=Some("semver-spec"),
1453+
// sbt defaults to scala 2.12.x and metals will report issues as it doesn't consider the project a scala 3 project
1454+
// (not the actual version we use to compile the project)
1455+
scalaVersion:= referenceVersion,
14531456
crossPaths:=false,// org.scala-lang:scala-library doesn't have a crosspath
14541457
// Add the source directories for the stdlib (non-boostrapped)
14551458
Compile/ unmanagedSourceDirectories:=Seq(baseDirectory.value/"src"),

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp