From b090f9748fff915df82f2a4908e7075f5cf1c91c Mon Sep 17 00:00:00 2001 From: Jason Zaugg Date: Thu, 3 Oct 2013 09:18:41 +0200 Subject: Rework cff8b569 to heal the windows build. - change newTermName to fix negative length names rather than reject them - restore the old logic in unspecializedName for names that result from AnyRef specialized type parameters. Why does fix the windows build? I remain none the wiser. --- test/files/run/global-showdef.scala | 2 +- test/junit/scala/tools/nsc/symtab/StdNamesTest.scala | 8 ++++---- 2 files changed, 5 insertions(+), 5 deletions(-) (limited to 'test') diff --git a/test/files/run/global-showdef.scala b/test/files/run/global-showdef.scala index 0dbaba979d..c3ace590ed 100644 --- a/test/files/run/global-showdef.scala +++ b/test/files/run/global-showdef.scala @@ -54,7 +54,7 @@ object Bippy { val run = new compiler.Run() run.compileSources(List(src)) } - (output split "\\n").toList + output.linesIterator.toList } def showClass(name: String) = lines("-Yshow:typer", "-Xshow-class", name) def showObject(name: String) = lines("-Yshow:typer", "-Xshow-object", name) diff --git a/test/junit/scala/tools/nsc/symtab/StdNamesTest.scala b/test/junit/scala/tools/nsc/symtab/StdNamesTest.scala index 05e69978c6..4a39cf9d48 100644 --- a/test/junit/scala/tools/nsc/symtab/StdNamesTest.scala +++ b/test/junit/scala/tools/nsc/symtab/StdNamesTest.scala @@ -28,8 +28,8 @@ class StdNamesTest { test(TermName("Tuple2"), TermName("Tuple2$mcII" + SPECIALIZED_SUFFIX)) test(TermName("foo"), TermName("foo$mIcD" + SPECIALIZED_SUFFIX)) test(TermName("foo"), TermName("foo$mIc" + SPECIALIZED_SUFFIX)) - test(TermName("T1"), TermName(s"T1$SPECIALIZED_SUFFIX")) - test(TermName(""), SPECIALIZED_SUFFIX) + test(nme.EMPTY, TermName(s"T1$SPECIALIZED_SUFFIX")) + test(nme.EMPTY, SPECIALIZED_SUFFIX) } @Test @@ -40,7 +40,7 @@ class StdNamesTest { test((TermName("Tuple2"), "II", ""), TermName("Tuple2$mcII" + SPECIALIZED_SUFFIX)) test((TermName("foo"), "D", "I"), TermName("foo$mIcD" + SPECIALIZED_SUFFIX)) test((TermName("foo"), "", "I"), TermName("foo$mIc" + SPECIALIZED_SUFFIX)) - test((TermName("T1"), "", ""), TermName(s"T1$SPECIALIZED_SUFFIX")) - test((TermName(""), "", ""), SPECIALIZED_SUFFIX) + test((nme.EMPTY, "T1", ""), TermName(s"T1$SPECIALIZED_SUFFIX")) + test((nme.EMPTY, "", ""), SPECIALIZED_SUFFIX) } } -- cgit v1.2.3