diff options
Diffstat (limited to 'src')
-rwxr-xr-x | src/compiler/scala/tools/nsc/interactive/Positions.scala | 4 | ||||
-rw-r--r-- | src/compiler/scala/tools/nsc/typechecker/Typers.scala | 3 |
2 files changed, 5 insertions, 2 deletions
diff --git a/src/compiler/scala/tools/nsc/interactive/Positions.scala b/src/compiler/scala/tools/nsc/interactive/Positions.scala index 9982e14815..2eaf32f6db 100755 --- a/src/compiler/scala/tools/nsc/interactive/Positions.scala +++ b/src/compiler/scala/tools/nsc/interactive/Positions.scala @@ -148,9 +148,9 @@ self: Global => tree setPos OffsetPosition(pos.source.get, currentPos.start) else { setChildrenPos(currentPos, children) - // temporary hack to work around issues with implicit resolution + val positionableChildren = children filter (isPositionable(_)) tree setPos new RangePosition( - pos.source.get, (children map (_.pos.start)).min, pos.point, (children map (_.pos.end)).max) + pos.source.get, (positionableChildren map (_.pos.start)).min, pos.point, (positionableChildren map (_.pos.end)).max) } currentPos = new RangePosition(pos.source.get, tree.pos.end, pos.point, pos.end) } diff --git a/src/compiler/scala/tools/nsc/typechecker/Typers.scala b/src/compiler/scala/tools/nsc/typechecker/Typers.scala index 4e4f75a4cb..02f6d20522 100644 --- a/src/compiler/scala/tools/nsc/typechecker/Typers.scala +++ b/src/compiler/scala/tools/nsc/typechecker/Typers.scala @@ -3708,6 +3708,8 @@ 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) => if (settings.debug.value) println("drop ex "+tree+" "+tp) @@ -3738,6 +3740,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: TypeError => tree.tpe = null //Console.println("caught "+ex+" in typed");//DEBUG |