From daee8e25238eaef13f17c3cfd6f26263452c0a37 Mon Sep 17 00:00:00 2001 From: Jakob Odersky Date: Tue, 9 Aug 2016 16:24:26 -0700 Subject: Javadoc: experimental proof-of-concept hack --- src/compiler/scala/tools/nsc/typechecker/Contexts.scala | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/compiler/scala/tools/nsc/typechecker/Contexts.scala b/src/compiler/scala/tools/nsc/typechecker/Contexts.scala index 16ef75c863..b9441a5cc4 100644 --- a/src/compiler/scala/tools/nsc/typechecker/Contexts.scala +++ b/src/compiler/scala/tools/nsc/typechecker/Contexts.scala @@ -1107,6 +1107,9 @@ trait Contexts { self: Analyzer => // Defined symbols take precedence over erroneous imports. else if (impSym.isError || impSym.name == nme.CONSTRUCTOR) impSym = NoSymbol + // EXTREME HACK: nested, static java classes that define same-named classes themselves + else if (unit.isJava) + defSym = NoSymbol // Otherwise they are irreconcilably ambiguous else return ambiguousDefnAndImport(defSym.alternatives.head.owner, imp1) -- cgit v1.2.3