aboutsummaryrefslogtreecommitdiff
path: root/src/dotty/tools/dotc/typer/Applications.scala
diff options
context:
space:
mode:
authorMartin Odersky <odersky@gmail.com>2014-01-06 20:31:12 +0100
committerMartin Odersky <odersky@gmail.com>2014-01-06 20:32:11 +0100
commit84cbb43bc3e4dc8399202763b371fda57ac3c072 (patch)
tree796421ed7ff0854436fb5ac72f1fd320cc7fad6b /src/dotty/tools/dotc/typer/Applications.scala
parentaff925e667a62af65bf0190c3318219d2218b3c1 (diff)
downloaddotty-84cbb43bc3e4dc8399202763b371fda57ac3c072.tar.gz
dotty-84cbb43bc3e4dc8399202763b371fda57ac3c072.tar.bz2
dotty-84cbb43bc3e4dc8399202763b371fda57ac3c072.zip
Remove debug output
Diffstat (limited to 'src/dotty/tools/dotc/typer/Applications.scala')
-rw-r--r--src/dotty/tools/dotc/typer/Applications.scala17
1 files changed, 3 insertions, 14 deletions
diff --git a/src/dotty/tools/dotc/typer/Applications.scala b/src/dotty/tools/dotc/typer/Applications.scala
index 485cba1f0..ec22fb029 100644
--- a/src/dotty/tools/dotc/typer/Applications.scala
+++ b/src/dotty/tools/dotc/typer/Applications.scala
@@ -788,12 +788,11 @@ trait Applications extends Compatibility { self: Typer =>
else /* 1/9 */ winsType1 || /* 2/27 */ !winsType2
}}
- def narrowMostSpecific(alts: List[TermRef], onTarget: Boolean = false)(implicit ctx: Context): List[TermRef] = track("narrowMostSpecific") {
+ def narrowMostSpecific(alts: List[TermRef])(implicit ctx: Context): List[TermRef] = track("narrowMostSpecific") {
(alts: @unchecked) match {
case alt :: alts1 =>
def winner(bestSoFar: TermRef, alts: List[TermRef]): TermRef = alts match {
case alt :: alts1 =>
- println(i"comparing ${alt.widen} ${bestSoFar.widen}")
winner(if (isAsGood(alt, bestSoFar)) alt else bestSoFar, alts1)
case nil =>
bestSoFar
@@ -817,11 +816,6 @@ trait Applications extends Compatibility { self: Typer =>
*/
def resolveOverloaded(alts: List[TermRef], pt: Type, targs: List[Type] = Nil)(implicit ctx: Context): List[TermRef] = track("resolveOverloaded") {
- val onTarget = alts.head.name == "toLowerCase".toTermName
-
- if (onTarget)
- println(i"resolveOverloaded $alts, pt = $pt")
-
def isDetermined(alts: List[TermRef]) = alts.isEmpty || alts.tail.isEmpty
/** The shape of given tree as a type; cannot handle named arguments. */
@@ -880,14 +874,10 @@ trait Applications extends Compatibility { self: Typer =>
alts filter (isApplicable(_, targs, args, resultType))
val alts1 = narrowBySize(alts)
- if (onTarget) println(i"narrow by size $alts")
-
if (isDetermined(alts1)) alts1
else {
val alts2 = narrowByShapes(alts1)
- if (onTarget) println(i"narrow by shapes $alts")
-
- if (isDetermined(alts2)) alts2
+ if (isDetermined(alts2)) alts2
else narrowByTrees(alts2, pt.typedArgs, resultType)
}
@@ -901,9 +891,8 @@ trait Applications extends Compatibility { self: Typer =>
case pt =>
alts filter (normalizedCompatible(_, pt))
}
- println(s"candidates = $alts")
if (isDetermined(candidates)) candidates
- else narrowMostSpecific(candidates, onTarget)
+ else narrowMostSpecific(candidates)
}
}