diff options
author | Jason Zaugg <jzaugg@gmail.com> | 2012-12-11 18:59:27 +0100 |
---|---|---|
committer | Jason Zaugg <jzaugg@gmail.com> | 2012-12-12 07:19:54 +0100 |
commit | f69b8468b76edc9f25a4cb97022a136be988b236 (patch) | |
tree | 11ee20533761c70f2b7bda9748e22ebda277acd2 /src/partest | |
parent | 79a43d78b27232be005755eb206fd9e4ce9a0625 (diff) | |
download | scala-f69b8468b76edc9f25a4cb97022a136be988b236.tar.gz scala-f69b8468b76edc9f25a4cb97022a136be988b236.tar.bz2 scala-f69b8468b76edc9f25a4cb97022a136be988b236.zip |
SI-6288 Fix positioning of label jumps
ICode generation was assigning the position of
the last label jump to all jumps to that particular
label def.
This problem is particularly annoying under the new
pattern matcher: a breakpoint in the body of the final
case will be triggered on the way out of the body of
any other case.
Thanks to @dragos for the expert guidance as we
wended our way through GenICode to the troublesome
code. Chalk up another bug for mutability.
I believe that the ICode output should be stable
enough to use a a .check file, if it proves otherwise
we should make it so.
Diffstat (limited to 'src/partest')
-rw-r--r-- | src/partest/scala/tools/partest/DirectTest.scala | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/partest/scala/tools/partest/DirectTest.scala b/src/partest/scala/tools/partest/DirectTest.scala index 8c18809ad6..483cb491a1 100644 --- a/src/partest/scala/tools/partest/DirectTest.scala +++ b/src/partest/scala/tools/partest/DirectTest.scala @@ -39,6 +39,10 @@ abstract class DirectTest extends App { // new compiler def newCompiler(args: String*): Global = { val settings = newSettings((CommandLineParser tokenize ("-d \"" + testOutput.path + "\" " + extraSettings)) ++ args.toList) + newCompiler(settings) + } + + def newCompiler(settings: Settings): Global = { if (settings.Yrangepos.value) new Global(settings, reporter(settings)) with interactive.RangePositions else new Global(settings, reporter(settings)) } |