From bc46a1b53603f1ecfa9061466c36909c51a19a55 Mon Sep 17 00:00:00 2001 From: Martin Odersky Date: Tue, 16 May 2006 10:55:19 +0000 Subject: Fixed bug 593 --- test/files/neg/bug593.check | 4 ++++ test/files/neg/bug593.scala | 2 ++ test/files/run/bug594.check | 2 ++ test/files/run/bug594.scala | 8 ++++++++ 4 files changed, 16 insertions(+) create mode 100644 test/files/neg/bug593.check create mode 100644 test/files/neg/bug593.scala create mode 100644 test/files/run/bug594.check create mode 100644 test/files/run/bug594.scala (limited to 'test') diff --git a/test/files/neg/bug593.check b/test/files/neg/bug593.check new file mode 100644 index 0000000000..c29e68da7a --- /dev/null +++ b/test/files/neg/bug593.check @@ -0,0 +1,4 @@ +bug593.scala:1 error: `extends' or `{' expected +trait Wrapper[T](x : T) { + ^ +one error found diff --git a/test/files/neg/bug593.scala b/test/files/neg/bug593.scala new file mode 100644 index 0000000000..df7199a42a --- /dev/null +++ b/test/files/neg/bug593.scala @@ -0,0 +1,2 @@ +trait Wrapper[T](x : T) { +} diff --git a/test/files/run/bug594.check b/test/files/run/bug594.check new file mode 100644 index 0000000000..814f4a4229 --- /dev/null +++ b/test/files/run/bug594.check @@ -0,0 +1,2 @@ +one +two diff --git a/test/files/run/bug594.scala b/test/files/run/bug594.scala new file mode 100644 index 0000000000..b120f47338 --- /dev/null +++ b/test/files/run/bug594.scala @@ -0,0 +1,8 @@ +object Test { + def main(args: Array[String]): Unit = { + val array = Array("one", "two", "three") + val firstTwo: Array[String] = array.subArray(0,2) + for(val x <- firstTwo) + Console.println(x) + } +} -- cgit v1.2.3