diff options
author | Jason Zaugg <jzaugg@gmail.com> | 2013-01-12 17:29:54 +0100 |
---|---|---|
committer | Jason Zaugg <jzaugg@gmail.com> | 2013-01-12 17:33:36 +0100 |
commit | 58bfa19332c4aac8b7250d5866cfb153ae78c9ad (patch) | |
tree | 211163bc47b9aea550d643f62ac9bf413108f298 /src/compiler/scala/tools/nsc/typechecker/Implicits.scala | |
parent | a2a37ed41fdfddeb44804f2dcc65b496c7fe0a3f (diff) | |
download | scala-58bfa19332c4aac8b7250d5866cfb153ae78c9ad.tar.gz scala-58bfa19332c4aac8b7250d5866cfb153ae78c9ad.tar.bz2 scala-58bfa19332c4aac8b7250d5866cfb153ae78c9ad.zip |
SI-6966 Fix regression in implicit resolution
Reverts this line: 9c09c17#L50L671. That value was
apparantly discarded intentionally.
Diffstat (limited to 'src/compiler/scala/tools/nsc/typechecker/Implicits.scala')
-rw-r--r-- | src/compiler/scala/tools/nsc/typechecker/Implicits.scala | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/src/compiler/scala/tools/nsc/typechecker/Implicits.scala b/src/compiler/scala/tools/nsc/typechecker/Implicits.scala index ed1e6d01e8..e435717839 100644 --- a/src/compiler/scala/tools/nsc/typechecker/Implicits.scala +++ b/src/compiler/scala/tools/nsc/typechecker/Implicits.scala @@ -668,7 +668,11 @@ trait Implicits { // duplicating the code here, but this is probably a // hotspot (and you can't just call typed, need to force // re-typecheck) - val checked = itree2 match { + // + // This is just called for the side effect of error detection, + // see SI-6966 to see what goes wrong if we use the result of this + // as the SearchResult. + itree2 match { case TypeApply(fun, args) => typedTypeApply(itree2, EXPRmode, fun, args) case Apply(TypeApply(fun, args), _) => typedTypeApply(itree2, EXPRmode, fun, args) // t2421c case t => t @@ -677,7 +681,7 @@ trait Implicits { if (context.hasErrors) fail("typing TypeApply reported errors for the implicit tree: " + context.errBuffer.head.errMsg) else { - val result = new SearchResult(checked, subst) + val result = new SearchResult(itree2, subst) if (Statistics.canEnable) Statistics.incCounter(foundImplicits) printInference("[success] found %s for pt %s".format(result, ptInstantiated)) result |