Skip to content

Commit

Permalink
improvement: Use distinct on ScalacOpt (#3139)
Browse files Browse the repository at this point in the history
I am still getting an issue with multiple same plugin options and my guess is that the distinct doesn't work, especially that it is hard to figure out what can actually be contained there. Moving distinct to the end should be a much safer option.

Related to #2708
  • Loading branch information
tgodzik authored Sep 2, 2024
1 parent 3d2fa93 commit dab5d9e
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions modules/build/src/main/scala/scala/build/Build.scala
Original file line number Diff line number Diff line change
Expand Up @@ -862,10 +862,10 @@ object Build {
)
}

val pluginScalacOptions = scalaArtifacts.compilerPlugins.distinct.map {
val pluginScalacOptions = scalaArtifacts.compilerPlugins.map {
case (_, _, path) =>
ScalacOpt(s"-Xplugin:$path")
}
}.distinct

val semanticDbTargetRootOptions: Seq[ScalacOpt] =
(semanticDbTargetRoot match
Expand Down

0 comments on commit dab5d9e

Please sign in to comment.