aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/dotty/tools/backend/jvm/DottyBackendInterface.scala7
1 files changed, 6 insertions, 1 deletions
diff --git a/src/dotty/tools/backend/jvm/DottyBackendInterface.scala b/src/dotty/tools/backend/jvm/DottyBackendInterface.scala
index 111a5f5f5..651c5d736 100644
--- a/src/dotty/tools/backend/jvm/DottyBackendInterface.scala
+++ b/src/dotty/tools/backend/jvm/DottyBackendInterface.scala
@@ -493,7 +493,12 @@ class DottyBackendInterface()(implicit ctx: Context) extends BackendInterface{
def superClass: Symbol = toDenot(sym).superClass
def enclClass: Symbol = toDenot(sym).enclosingClass
def linkedClassOfClass: Symbol = linkedClass
- def linkedClass: Symbol = toDenot(sym).linkedClass //exitingPickler(sym.linkedClassOfClass)
+ def linkedClass: Symbol = {
+ val ct = ctx.withPhase(ctx.flattenPhase.prev)
+ toDenot(sym)(ct).linkedClass(ct)
+ // java.util.Attributes.Name$ -> java$util$Attributes$Name$ no companion class after flatten
+ // see bug #348
+ } //exitingPickler(sym.linkedClassOfClass)
def companionClass: Symbol = toDenot(sym).companionClass
def companionModule: Symbol = toDenot(sym).companionModule
def companionSymbol: Symbol = if (sym is Flags.Module) companionClass else companionModule