Skip to content

Commit

Permalink
Fix errors to use dealiased types
Browse files Browse the repository at this point in the history
  • Loading branch information
ausmarton committed Nov 27, 2023
1 parent 08a0aad commit b46fb01
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions compiler/src/dotty/tools/dotc/printing/PlainPrinter.scala
Original file line number Diff line number Diff line change
Expand Up @@ -192,10 +192,11 @@ class PlainPrinter(_ctx: Context) extends Printer {
case tp: TermRef if tp.denot.isOverloaded =>
"<overloaded " ~ toTextRef(tp) ~ ">"
case tp: TypeRef =>
val dealisedType = selectionString(tp.dealias.asInstanceOf[NamedType])
if (printWithoutPrefix.contains(tp.symbol))
selectionString(tp.dealias.asInstanceOf[NamedType])
dealisedType
else
toTextPrefixOf(tp) ~ selectionString(tp)
toTextPrefixOf(tp) ~ dealisedType
case tp: TermParamRef =>
ParamRefNameString(tp) ~ lambdaHash(tp.binder) ~ ".type"
case tp: TypeParamRef =>
Expand Down

0 comments on commit b46fb01

Please sign in to comment.