Browse files

removes the assertion in missingHook

In the current synchronization scheme multiple threads can enter the
missingHook trying to materialize a package, which hasn't been created.

That's fine, because makeScalaPackage, which creates and enters package
symbols is synchronized and checks whether the creation is necessary
before commencing. Therefore even if makeScalaPackage is called multiple
times in rapid succession, the calls will be serialized and all calls
except the first one won't do anything.
  • Loading branch information...
1 parent f4dd56c commit 73d079fb383f82e825c2a40b397b64288e218fe9 @xeno-by xeno-by committed Jan 29, 2013
Showing with 0 additions and 2 deletions.
  1. +0 −2 src/reflect/scala/reflect/runtime/JavaMirrors.scala
@@ -1264,8 +1264,6 @@ private[reflect] trait JavaMirrors extends internal.SymbolTable with api.JavaUni
override def missingHook(owner: Symbol, name: Name): Symbol = {
if (owner.hasPackageFlag) {
val mirror = mirrorThatLoaded(owner)
- // todo. this makes toolbox tests pass, but it's a mere workaround for SI-5865
-// assert(( decl name) == NoSymbol, s"already exists: $owner . $name")
if (owner.isRootSymbol && mirror.tryJavaClass(name.toString).isDefined)
return decl name
if (name.isTermName && !owner.isEmptyPackageClass)

1 comment on commit 73d079f

Job pr-rangepos-per-commit failed for 73d079f (results):

Took 29 s.
sad kitty
to rebuild, comment "PLS REBUILD/pr-rangepos-per-commit@73d079fb383f82e825c2a40b397b64288e218fe9"on PR #2083

Please sign in to comment.