diff options
author | Miles Sabin <miles@milessabin.com> | 2009-07-15 13:01:43 +0000 |
---|---|---|
committer | Miles Sabin <miles@milessabin.com> | 2009-07-15 13:01:43 +0000 |
commit | 69e1ddb55a7f122715dbed337de73f595ae00dc3 (patch) | |
tree | c545190e2d2a79070ac49e76886bdca34f94bdba /src/compiler/scala/tools/nsc/typechecker/Typers.scala | |
parent | 370817ac9736f67775a150f679bb5a4c01356ecb (diff) | |
download | scala-69e1ddb55a7f122715dbed337de73f595ae00dc3.tar.gz scala-69e1ddb55a7f122715dbed337de73f595ae00dc3.tar.bz2 scala-69e1ddb55a7f122715dbed337de73f595ae00dc3.zip |
Added ControlException marker trait and update ...
Added ControlException marker trait and update various exceptions to
mix it in; the typer now correctly propagates ControlExceptions rather
than reporting them; the IDE reports attempts to log ControlExceptions;
Global.signalDone no longer leaks ValidateErrors back into the typer;
the set of compiler options offered by the IDE has been updated.
Diffstat (limited to 'src/compiler/scala/tools/nsc/typechecker/Typers.scala')
-rw-r--r-- | src/compiler/scala/tools/nsc/typechecker/Typers.scala | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/compiler/scala/tools/nsc/typechecker/Typers.scala b/src/compiler/scala/tools/nsc/typechecker/Typers.scala index f576c17ad1..b1ed6da208 100644 --- a/src/compiler/scala/tools/nsc/typechecker/Typers.scala +++ b/src/compiler/scala/tools/nsc/typechecker/Typers.scala @@ -11,7 +11,9 @@ package scala.tools.nsc.typechecker import scala.collection.mutable.{HashMap, ListBuffer} +import scala.util.control.ControlException import scala.compat.Platform.currentTime +import scala.tools.nsc.interactive.RangePositions import scala.tools.nsc.util.{HashSet, Position, Set, NoPosition, SourceFile} import symtab.Flags._ import util.HashSet @@ -3735,7 +3737,6 @@ trait Typers { self: Analyzer => * @return ... */ def typed(tree: Tree, mode: Int, pt: Type): Tree = { - import scala.tools.nsc.interactive.CompilerControl def dropExistential(tp: Type): Type = tp match { case ExistentialType(tparams, tpe) => @@ -3767,7 +3768,7 @@ trait Typers { self: Analyzer => if (phase.id <= currentRun.typerPhase.id) signalDone(context.asInstanceOf[analyzer.Context], tree, result) result } catch { - case ex: CompilerControl#FreshRunReq => throw ex + case ex: ControlException => throw ex case ex: TypeError => tree.tpe = null //Console.println("caught "+ex+" in typed");//DEBUG |