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

[1.x] Use inclusive language on internal terminology #1505

Merged
merged 1 commit into from
Nov 26, 2024
Merged
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
Original file line number Diff line number Diff line change
Expand Up @@ -266,12 +266,12 @@ object ScalaInstance {

/** Return all the required Scala jars from a path `scalaHome`. */
def allJars(scalaHome: File): Seq[File] =
IO.listFiles(scalaLib(scalaHome)).toIndexedSeq.filter(f => !blacklist(f.getName))
IO.listFiles(scalaLib(scalaHome)).toIndexedSeq.filter(f => !excludeList(f.getName))

private[this] def scalaLib(scalaHome: File): File =
new File(scalaHome, "lib")

private[this] val blacklist: Set[String] = Set(
private[this] val excludeList: Set[String] = Set(
Copy link
Member Author

@Friendseeker Friendseeker Nov 25, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Btw I actually don't understand what does the excludeList do, but I guess there's probably a better way compared to special casing a bunch of jars...

If someone can decipher what's going on, might be able to remove excludeList altogether.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Likely this code is related to sbt and Zinc's use of layered classloader, where we construct ClassLoader instance using Scala distribution of a specific version (scala-library.jar etc) for performance. In this case, we're trying to exclude non-essential JARs that were historically distributed and/or placed in scalaHome (for scala compiler developers this could be someone on disk)?

"scala-actors.jar",
"scalacheck.jar",
"scala-partest.jar",
Expand Down