Merge pull request #7735 from Friendseeker/remove-gc-workaround-2

[2.x] Remove deprecated `System.runFinalization`
This commit is contained in:
eugene yokota 2024-10-06 22:12:51 -04:00 committed by GitHub
commit d5d722df3c
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 0 additions and 8 deletions

View File

@ -36,14 +36,6 @@ private[sbt] object GCUtil {
log.debug(s"Forcing garbage collection...")
// Force the detection of finalizers for scala.reflect weakhashsets
System.gc()
// Force finalizers to run.
try {
System.runFinalization()
} catch {
case _: NoSuchMethodError =>
}
// Force actually cleaning the weak hash maps.
System.gc()
} catch {
case NonFatal(_) => // gotta catch em all
}