summaryrefslogtreecommitdiff
path: root/src/partest
diff options
context:
space:
mode:
authorAdriaan Moors <adriaan.moors@epfl.ch>2012-07-20 14:54:05 -0700
committerAdriaan Moors <adriaan.moors@epfl.ch>2012-07-20 14:54:05 -0700
commit15fba6bd2eb45ca47e975ef033aaf20136d71c67 (patch)
tree4c4582657e095e8fb711af2c23ef6e0ae61a3233 /src/partest
parentb0742ebacb5fb5982baa1096ad12457d9b14124e (diff)
parent32fd97df41bb2e99018f024f41b06490e41bd7ad (diff)
downloadscala-15fba6bd2eb45ca47e975ef033aaf20136d71c67.tar.gz
scala-15fba6bd2eb45ca47e975ef033aaf20136d71c67.tar.bz2
scala-15fba6bd2eb45ca47e975ef033aaf20136d71c67.zip
Merge pull request #924 from hubertp/2.10.x-issue/5385
Fix for SI-5385.
Diffstat (limited to 'src/partest')
-rw-r--r--src/partest/scala/tools/partest/DirectTest.scala5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/partest/scala/tools/partest/DirectTest.scala b/src/partest/scala/tools/partest/DirectTest.scala
index 4e7f36bdc9..5b4e1b4b25 100644
--- a/src/partest/scala/tools/partest/DirectTest.scala
+++ b/src/partest/scala/tools/partest/DirectTest.scala
@@ -38,7 +38,8 @@ abstract class DirectTest extends App {
// new compiler
def newCompiler(args: String*): Global = {
val settings = newSettings((CommandLineParser tokenize extraSettings) ++ args.toList)
- new Global(settings)
+ if (settings.Yrangepos.value) new Global(settings) with interactive.RangePositions
+ else new Global(settings)
}
def newSources(sourceCodes: String*) = sourceCodes.toList.zipWithIndex map {
case (src, idx) => new BatchSourceFile("newSource" + (idx + 1), src)
@@ -69,7 +70,7 @@ abstract class DirectTest extends App {
/** Constructor/main body **/
try show()
- catch { case t => println(t) ; t.printStackTrace ; sys.exit(1) }
+ catch { case t => println(t.getMessage) ; t.printStackTrace ; sys.exit(1) }
/** Debugger interest only below this line **/
protected def isDebug = (sys.props contains "partest.debug") || (sys.env contains "PARTEST_DEBUG")