aboutsummaryrefslogtreecommitdiff
path: root/src/dotty/tools/dotc/core/TypeComparer.scala
diff options
context:
space:
mode:
authorMartin Odersky <odersky@gmail.com>2015-05-20 10:10:44 +0200
committerMartin Odersky <odersky@gmail.com>2015-05-21 17:41:16 +0200
commit1746ae11926e2f09ed50e62273669b6196e60547 (patch)
treead2d13692f662c318bbd0fbf8b0fb9e493664d32 /src/dotty/tools/dotc/core/TypeComparer.scala
parentde7a5bb049fadaa2078107358e51de273a15d515 (diff)
downloaddotty-1746ae11926e2f09ed50e62273669b6196e60547.tar.gz
dotty-1746ae11926e2f09ed50e62273669b6196e60547.tar.bz2
dotty-1746ae11926e2f09ed50e62273669b6196e60547.zip
Rename Reporter#echo -> println
More refular that way. Also, change some raw printlns in low-level code to reporter.printlns in order to harden them against prints over prints.
Diffstat (limited to 'src/dotty/tools/dotc/core/TypeComparer.scala')
-rw-r--r--src/dotty/tools/dotc/core/TypeComparer.scala12
1 files changed, 6 insertions, 6 deletions
diff --git a/src/dotty/tools/dotc/core/TypeComparer.scala b/src/dotty/tools/dotc/core/TypeComparer.scala
index 1feeaca64..6aee47945 100644
--- a/src/dotty/tools/dotc/core/TypeComparer.scala
+++ b/src/dotty/tools/dotc/core/TypeComparer.scala
@@ -1148,13 +1148,13 @@ class TypeComparer(initctx: Context) extends DotClass with ConstraintHandling wi
}
/** Show subtype goal that led to an assertion failure */
- def showGoal(tp1: Type, tp2: Type) = {
- println(disambiguated(implicit ctx => s"assertion failure for ${tp1.show} <:< ${tp2.show}, frozen = $frozenConstraint"))
+ def showGoal(tp1: Type, tp2: Type)(implicit ctx: Context) = {
+ ctx.println(disambiguated(implicit ctx => s"assertion failure for ${tp1.show} <:< ${tp2.show}, frozen = $frozenConstraint"))
def explainPoly(tp: Type) = tp match {
- case tp: PolyParam => println(s"polyparam ${tp.show} found in ${tp.binder.show}")
- case tp: TypeRef if tp.symbol.exists => println(s"typeref ${tp.show} found in ${tp.symbol.owner.show}")
- case tp: TypeVar => println(s"typevar ${tp.show}, origin = ${tp.origin}")
- case _ => println(s"${tp.show} is a ${tp.getClass}")
+ case tp: PolyParam => ctx.println(s"polyparam ${tp.show} found in ${tp.binder.show}")
+ case tp: TypeRef if tp.symbol.exists => ctx.println(s"typeref ${tp.show} found in ${tp.symbol.owner.show}")
+ case tp: TypeVar => ctx.println(s"typevar ${tp.show}, origin = ${tp.origin}")
+ case _ => ctx.println(s"${tp.show} is a ${tp.getClass}")
}
explainPoly(tp1)
explainPoly(tp2)