File tree Expand file tree Collapse file tree 2 files changed +6
-5
lines changed
compiler/src/dotty/tools/dotc/printing Expand file tree Collapse file tree 2 files changed +6
-5
lines changed Original file line number Diff line number Diff line change @@ -146,7 +146,7 @@ class PlainPrinter(_ctx: Context) extends Printer {
146146 else
147147 toTextPrefix(tp.prefix) ~ selectionString(tp)
148148 case tp : TermParamRef =>
149- ParamRefNameString (tp) ~ " .type"
149+ ParamRefNameString (tp) ~ lambdaHash(tp.binder) ~ " .type"
150150 case tp : TypeParamRef =>
151151 ParamRefNameString (tp) ~ lambdaHash(tp.binder)
152152 case tp : SingletonType =>
@@ -237,9 +237,10 @@ class PlainPrinter(_ctx: Context) extends Printer {
237237 def toTextSingleton (tp : SingletonType ): Text =
238238 " (" ~ toTextRef(tp) ~ " : " ~ toTextGlobal(tp.underlying) ~ " )"
239239
240- protected def paramsText (tp : LambdaType ): Text = {
241- def paramText (name : Name , tp : Type ) = toText(name) ~ toTextRHS(tp)
242- Text (tp.paramNames.lazyZip(tp.paramInfos).map(paramText), " , " )
240+ protected def paramsText (lam : LambdaType ): Text = {
241+ def paramText (name : Name , tp : Type ) =
242+ toText(name) ~ lambdaHash(lam) ~ toTextRHS(tp)
243+ Text (lam.paramNames.lazyZip(lam.paramInfos).map(paramText), " , " )
243244 }
244245
245246 protected def ParamRefNameString (name : Name ): String = name.toString
Original file line number Diff line number Diff line change @@ -212,7 +212,7 @@ class RefinedPrinter(_ctx: Context) extends PlainPrinter(_ctx) {
212212 toTextInfixType(tpnme.raw.BAR , tp1, tp2) { toText(tpnme.raw.BAR ) }
213213 case EtaExpansion (tycon) if ! printDebug =>
214214 toText(tycon)
215- case tp : RefinedType if defn.isFunctionType(tp) =>
215+ case tp : RefinedType if defn.isFunctionType(tp) && ! printDebug =>
216216 toTextDependentFunction(tp.refinedInfo.asInstanceOf [MethodType ])
217217 case tp : TypeRef =>
218218 if (tp.symbol.isAnonymousClass && ! ctx.settings.uniqid.value)
You can’t perform that action at this time.
0 commit comments