File tree Expand file tree Collapse file tree 1 file changed +5
-6
lines changed
src/dotty/tools/dotc/printing Expand file tree Collapse file tree 1 file changed +5
-6
lines changed Original file line number Diff line number Diff line change @@ -45,8 +45,10 @@ class RefinedPrinter(_ctx: Context) extends PlainPrinter(_ctx) {
45
45
46
46
override def nameString (name : Name ): String = name.decode.toString
47
47
48
- override protected def simpleNameString (sym : Symbol ): String =
49
- sym.name.decode.toString
48
+ override protected def simpleNameString (sym : Symbol ): String = {
49
+ val name = sym.originalName
50
+ nameString(if (sym is ExpandedTypeParam ) name.asTypeName.unexpandedName else name)
51
+ }
50
52
51
53
override protected def fullNameOwner (sym : Symbol ) = {
52
54
val owner = super .fullNameOwner(sym)
@@ -86,10 +88,7 @@ class RefinedPrinter(_ctx: Context) extends PlainPrinter(_ctx) {
86
88
else {
87
89
val tsym = tp.parent.member(tp.refinedName).symbol
88
90
if (! tsym.exists) super .refinementNameString(tp)
89
- else {
90
- val name = tsym.originalName
91
- nameString(if (tsym is ExpandedTypeParam ) name.asTypeName.unexpandedName else name)
92
- }
91
+ else simpleNameString(tsym)
93
92
}
94
93
95
94
override def toText (tp : Type ): Text = controlled {
You can’t perform that action at this time.
0 commit comments