summaryrefslogtreecommitdiff
path: root/src/compiler/scala/tools/nsc/typechecker/Typers.scala
diff options
context:
space:
mode:
authorMartin Odersky <odersky@gmail.com>2011-04-29 15:35:37 +0000
committerMartin Odersky <odersky@gmail.com>2011-04-29 15:35:37 +0000
commit8792dda476e33af1070b11f0af288897dff995ca (patch)
treee1b5b8a7a61af571ff1cde107fa4a245393cdfea /src/compiler/scala/tools/nsc/typechecker/Typers.scala
parent96ab92d67c5ea5af3f322cd22205139b1bc846b8 (diff)
downloadscala-8792dda476e33af1070b11f0af288897dff995ca.tar.gz
scala-8792dda476e33af1070b11f0af288897dff995ca.tar.bz2
scala-8792dda476e33af1070b11f0af288897dff995ca.zip
Ignore type errors raised in later phases that ...
Ignore type errors raised in later phases that are due to mismatching existentials. Quick fix to address lift build failures. Review by dragos.
Diffstat (limited to 'src/compiler/scala/tools/nsc/typechecker/Typers.scala')
-rw-r--r--src/compiler/scala/tools/nsc/typechecker/Typers.scala13
1 files changed, 12 insertions, 1 deletions
diff --git a/src/compiler/scala/tools/nsc/typechecker/Typers.scala b/src/compiler/scala/tools/nsc/typechecker/Typers.scala
index add3bca6f2..233caaca32 100644
--- a/src/compiler/scala/tools/nsc/typechecker/Typers.scala
+++ b/src/compiler/scala/tools/nsc/typechecker/Typers.scala
@@ -925,7 +925,18 @@ trait Typers extends Modes {
log("error tree = "+tree)
if (settings.explaintypes.value) explainTypes(tree.tpe, pt)
}
- typeErrorTree(tree, tree.tpe, pt)
+ try {
+ typeErrorTree(tree, tree.tpe, pt)
+ } catch {
+ case ex: TypeError =>
+ if (phase.id > currentRun.typerPhase.id &&
+ tree.tpe.isInstanceOf[ExistentialType] &&
+ pt.isInstanceOf[ExistentialType])
+ // ignore type errors raised in later phases that are due to mismatching existentials
+ tree
+ else
+ throw ex
+ }
}
}
}