aboutsummaryrefslogtreecommitdiff
path: root/src/dotty/tools/dotc/printing/PlainPrinter.scala
diff options
context:
space:
mode:
authorMartin Odersky <odersky@gmail.com>2013-08-30 11:10:37 +0200
committerMartin Odersky <odersky@gmail.com>2013-08-30 11:10:37 +0200
commit860fd2eb286c48d36655ad99a068a2e61bdb1381 (patch)
tree0c75f7aa2228adae973a16ec5b5afccaaa7c68be /src/dotty/tools/dotc/printing/PlainPrinter.scala
parent28f8102d1b4e8c8fd2d2f1838b49e70844245a5f (diff)
downloaddotty-860fd2eb286c48d36655ad99a068a2e61bdb1381.tar.gz
dotty-860fd2eb286c48d36655ad99a068a2e61bdb1381.tar.bz2
dotty-860fd2eb286c48d36655ad99a068a2e61bdb1381.zip
More tests and fixes related to inference.
Main blooper: TypeVars got dereferenced in all Typemaps, so disappeared too quickly from types during inference.
Diffstat (limited to 'src/dotty/tools/dotc/printing/PlainPrinter.scala')
-rw-r--r--src/dotty/tools/dotc/printing/PlainPrinter.scala5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/dotty/tools/dotc/printing/PlainPrinter.scala b/src/dotty/tools/dotc/printing/PlainPrinter.scala
index b4e2e3770..f86075d83 100644
--- a/src/dotty/tools/dotc/printing/PlainPrinter.scala
+++ b/src/dotty/tools/dotc/printing/PlainPrinter.scala
@@ -125,7 +125,8 @@ class PlainPrinter(_ctx: Context) extends Printer {
case tp: ExprType =>
changePrec(GlobalPrec) { "=> " ~ toText(tp.resultType) }
case tp: PolyType =>
- def paramText(name: TypeName, bounds: TypeBounds) = toText(polyParamName(name)) ~ ": " ~ toText(bounds)
+ def paramText(name: TypeName, bounds: TypeBounds) =
+ toText(polyParamName(name)) ~ toText(bounds)
changePrec(GlobalPrec) {
"[" ~
Text((tp.paramNames, tp.paramBounds).zipped map paramText, ", ") ~
@@ -136,7 +137,7 @@ class PlainPrinter(_ctx: Context) extends Printer {
case AnnotatedType(annot, tpe) =>
toTextLocal(tpe) ~ " " ~ toText(annot)
case tp: TypeVar =>
- toTextLocal(tp.underlying)
+ toTextLocal(tp.underlying) ~ "'" // debug for now, so that we can see where the TypeVars are.
case _ =>
tp.fallbackToText(this)
}