File tree Expand file tree Collapse file tree 1 file changed +0
-11
lines changed
src/compiler/scala/tools/nsc/typechecker Expand file tree Collapse file tree 1 file changed +0
-11
lines changed Original file line number Diff line number Diff line change @@ -467,17 +467,6 @@ trait Namers extends MethodSynthesis {
467
467
468
468
val existingModule = context.scope lookupModule tree.name
469
469
if (existingModule.isModule && ! existingModule.hasPackageFlag && inCurrentScope(existingModule) && (currentRun.canRedefine(existingModule) || existingModule.isSynthetic)) {
470
- // This code accounts for the way the package objects found in the classpath are opened up
471
- // early by the completer of the package itself. If the `packageobjects` phase then finds
472
- // the same package object in sources, we have to clean the slate and remove package object
473
- // members from the package class.
474
- //
475
- // TODO scala/bug#4695 Pursue the approach in https://github.com/scala/scala/pull/2789 that avoids
476
- // opening up the package object on the classpath at all if one exists in source.
477
- if (existingModule.isPackageObject) {
478
- val packageScope = existingModule.enclosingPackageClass.rawInfo.decls
479
- packageScope.foreach(mem => if (mem.owner != existingModule.enclosingPackageClass) packageScope unlink mem)
480
- }
481
470
updatePosFlags(existingModule, tree.pos, moduleFlags)
482
471
setPrivateWithin(tree, existingModule)
483
472
existingModule.moduleClass andAlso (setPrivateWithin(tree, _))
You can’t perform that action at this time.
0 commit comments